/////////////////////////////////////////////////////////////////////////////
// Name: wx/richtext/richtextimagedlg.h
-// Purpose:
+// Purpose:
// Author: Mingquan Yang
-// Modified by:
+// Modified by:
// Created: Wed 02 Jun 2010 11:27:23 CST
-// RCS-ID:
+// RCS-ID:
// Copyright: (c) Mingquan Yang
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
*/
class WXDLLIMPEXP_RICHTEXT wxRichTextImageDialog: public wxDialog
-{
+{
DECLARE_DYNAMIC_CLASS( wxRichTextImageDialog )
DECLARE_EVENT_TABLE()
/// Creates the controls and sizers
void CreateControls();
+ /// Set the dimension into the value and units controls
+ void SetDimensionValue(wxTextAttrDimension& dim, wxTextCtrl* valueCtrl, wxComboBox* unitsCtrl);
+
+ /// Get the dimension from the value and units controls
+ void GetDimensionValue(wxTextAttrDimension& dim, wxTextCtrl* valueCtrl, wxComboBox* unitsCtrl);
+
////@begin wxRichTextImageDialog event handler declarations
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_RICHTEXTIMAGEDIALOG_PARA_UP
static bool ShowToolTips();
/// Set the image attribute
- void SetImageAttr(const wxRichTextAnchoredObjectAttr& attr);
+ void SetImageAttr(const wxRichTextAttr& textAttr);
wxRichTextImage* ApplyImageAttr();
/// Set the anchored object
/// Convert CM to MM
bool ConvertFromString(const wxString& string, int& ret, int scale);
private:
- wxRichTextAnchoredObjectAttr m_attr;
+ wxRichTextAttr m_textAttr;
+
////@begin wxRichTextImageDialog member variables
- wxComboBox* m_alignment;
wxComboBox* m_float;
wxTextCtrl* m_width;
wxComboBox* m_unitsW;
/// Control identifiers
enum {
ID_WXRICHTEXTIMAGEPAGE = 10015,
- ID_COMBOBOX_ALIGN = 10016,
ID_RICHTEXTIMAGEDIALOG_FLOATING_MODE = 10017,
ID_RICHTEXTIMAGEDIALOG_WIDTH = 10018,
ID_RICHTEXTIMAGEDIALOG_UNITS_W = 10019,