X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d2d0adc7765dfe904f0f7e97d85a2638c934a7d6..96defed03c190cb602ed4f7ca6e962a49e10dddd:/include/wx/richtext/richtextformatdlg.h diff --git a/include/wx/richtext/richtextformatdlg.h b/include/wx/richtext/richtextformatdlg.h index af41de9086..5a69bf5683 100644 --- a/include/wx/richtext/richtextformatdlg.h +++ b/include/wx/richtext/richtextformatdlg.h @@ -30,8 +30,8 @@ #include "wx/richtext/richtextbuffer.h" #include "wx/richtext/richtextstyles.h" -class WXDLLIMPEXP_RICHTEXT wxRichTextFormattingDialog; -class WXDLLIMPEXP_CORE wxImageList; +class WXDLLIMPEXP_FWD_RICHTEXT wxRichTextFormattingDialog; +class WXDLLIMPEXP_FWD_CORE wxImageList; /*! * Flags determining the pages and buttons to be created in the dialog @@ -118,7 +118,7 @@ DECLARE_CLASS(wxRichTextFormattingDialog) public: wxRichTextFormattingDialog() { Init(); } - wxRichTextFormattingDialog(long flags, wxWindow* parent, const wxString& title = _("Formatting"), wxWindowID id = wxID_ANY, + wxRichTextFormattingDialog(long flags, wxWindow* parent, const wxString& title = wxGetTranslation(wxT("Formatting")), wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& sz = wxDefaultSize, long style = wxDEFAULT_DIALOG_STYLE) { @@ -130,7 +130,7 @@ public: void Init(); - bool Create(long flags, wxWindow* parent, const wxString& title = _("Formatting"), wxWindowID id = wxID_ANY, + bool Create(long flags, wxWindow* parent, const wxString& title = wxGetTranslation(wxT("Formatting")), wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& sz = wxDefaultSize, long style = wxDEFAULT_DIALOG_STYLE); @@ -138,7 +138,7 @@ public: virtual bool GetStyle(wxRichTextCtrl* ctrl, const wxRichTextRange& range); /// Set the attributes and optionally update the display - virtual bool SetStyle(const wxTextAttrEx& style, bool update = true); + virtual bool SetStyle(const wxTextAttr& style, bool update = true); /// Set the style definition and optionally update the display virtual bool SetStyleDefinition(const wxRichTextStyleDefinition& styleDef, wxRichTextStyleSheet* sheet, bool update = true); @@ -156,9 +156,9 @@ public: virtual bool ApplyStyle(wxRichTextCtrl* ctrl, const wxRichTextRange& range, int flags = wxRICHTEXT_SETSTYLE_WITH_UNDO|wxRICHTEXT_SETSTYLE_OPTIMIZE); /// Gets and sets the attributes - const wxTextAttrEx& GetAttributes() const { return m_attributes; } - wxTextAttrEx& GetAttributes() { return m_attributes; } - void SetAttributes(const wxTextAttrEx& attr) { m_attributes = attr; } + const wxTextAttr& GetAttributes() const { return m_attributes; } + wxTextAttr& GetAttributes() { return m_attributes; } + void SetAttributes(const wxTextAttr& attr) { m_attributes = attr; } /// Transfers the data and from to the window virtual bool TransferDataToWindow(); @@ -183,7 +183,7 @@ public: static wxRichTextFormattingDialog* GetDialog(wxWindow* win); /// Helper for pages to get the attributes - static wxTextAttrEx* GetDialogAttributes(wxWindow* win); + static wxTextAttr* GetDialogAttributes(wxWindow* win); /// Helper for pages to get the style static wxRichTextStyleDefinition* GetDialogStyleDefinition(wxWindow* win); @@ -200,7 +200,7 @@ public: protected: wxImageList* m_imageList; - wxTextAttrEx m_attributes; + wxTextAttr m_attributes; wxRichTextStyleDefinition* m_styleDefinition; wxRichTextStyleSheet* m_styleSheet; wxArrayInt m_pageIds; // mapping of book control indexes to page ids @@ -218,13 +218,14 @@ DECLARE_EVENT_TABLE() class WXDLLIMPEXP_RICHTEXT wxRichTextFontPreviewCtrl : public wxWindow { public: - wxRichTextFontPreviewCtrl(wxWindow *parent, wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& sz = wxDefaultSize, long style = 0) : - wxWindow(parent, id, pos, sz, style) - { - SetBackgroundColour(*wxWHITE); - } + wxRichTextFontPreviewCtrl(wxWindow *parent, wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& sz = wxDefaultSize, long style = 0); + + void SetTextEffects(int effects) { m_textEffects = effects; } + int GetTextEffects() const { return m_textEffects; } private: + int m_textEffects; + void OnPaint(wxPaintEvent& event); DECLARE_EVENT_TABLE() };