]> git.saurik.com Git - wxWidgets.git/blobdiff - src/richtext/richtextstyles.cpp
Added wxDataViewEvent::SetDragFlags() and GetDropEffect() methods.
[wxWidgets.git] / src / richtext / richtextstyles.cpp
index c0cc55761f741c5c655a2e6a3955681f541550dd..cac6a8b1d62c9ae2b57580656ca8bc6745611375 100644 (file)
@@ -47,11 +47,12 @@ void wxRichTextStyleDefinition::Copy(const wxRichTextStyleDefinition& def)
     m_baseStyle = def.m_baseStyle;
     m_style = def.m_style;
     m_description = def.m_description;
+    m_properties = def.m_properties;
 }
 
 bool wxRichTextStyleDefinition::Eq(const wxRichTextStyleDefinition& def) const
 {
-    return (m_name == def.m_name && m_baseStyle == def.m_baseStyle && m_style == def.m_style);
+    return (m_name == def.m_name && m_baseStyle == def.m_baseStyle && m_style == def.m_style && m_properties == def.m_properties);
 }
 
 /// Gets the style combined with the base style
@@ -357,7 +358,7 @@ wxRichTextStyleDefinition* wxRichTextStyleSheet::FindStyle(const wxList& list, c
     for (wxList::compatibility_iterator node = list.GetFirst(); node; node = node->GetNext())
     {
         wxRichTextStyleDefinition* def = (wxRichTextStyleDefinition*) node->GetData();
-        if (def->GetName().Lower() == name.Lower())
+        if (def->GetName() == name)
             return def;
     }
 
@@ -442,7 +443,7 @@ bool wxRichTextStyleSheet::AddListStyle(wxRichTextListStyleDefinition* def)
 /// Add a definition to the box style list
 bool wxRichTextStyleSheet::AddBoxStyle(wxRichTextBoxStyleDefinition* def)
 {
-    def->GetStyle().SetParagraphStyleName(def->GetName());
+    def->GetStyle().GetTextBoxAttr().SetBoxStyleName(def->GetName());
     return AddStyle(m_boxStyleDefinitions, def);
 }
 
@@ -523,6 +524,7 @@ void wxRichTextStyleSheet::Copy(const wxRichTextStyleSheet& sheet)
 
     SetName(sheet.GetName());
     SetDescription(sheet.GetDescription());
+    m_properties = sheet.m_properties;
 }
 
 /// Equality
@@ -1209,8 +1211,8 @@ END_EVENT_TABLE()
 bool wxRichTextStyleComboPopup::Create( wxWindow* parent )
 {
     int borderStyle = GetDefaultBorder();
-    if (borderStyle == wxBORDER_SUNKEN)
-        borderStyle = wxBORDER_SIMPLE;
+    if (borderStyle == wxBORDER_SUNKEN || borderStyle == wxBORDER_NONE)
+        borderStyle = wxBORDER_THEME;
 
     return wxRichTextStyleListBox::Create(parent, wxID_ANY,
                                   wxPoint(0,0), wxDefaultSize,