#include "wx/bookctrl.h"
#include "wx/colordlg.h"
-#include "wx/fontenum.h"
#include "wx/settings.h"
#include "wx/module.h"
#include "wx/imaglist.h"
#include "../../src/richtext/richtexttabspage.cpp"
#include "../../src/richtext/richtextbulletspage.cpp"
#include "../../src/richtext/richtextstylepage.cpp"
+#include "../../src/richtext/richtextliststylepage.cpp"
#else
#include "richtextfontpage.cpp"
#include "richtextindentspage.cpp"
#include "richtexttabspage.cpp"
#include "richtextbulletspage.cpp"
+// Digital Mars can't cope with this much code
+#ifndef __DMC__
+ #include "richtextliststylepage.cpp"
+#endif
#include "richtextstylepage.cpp"
#endif
#define wxRICHTEXT_USE_TOOLBOOK false
#endif
+bool wxRichTextFormattingDialog::sm_showToolTips = false;
+
IMPLEMENT_CLASS(wxRichTextFormattingDialog, wxPropertySheetDialog)
BEGIN_EVENT_TABLE(wxRichTextFormattingDialog, wxPropertySheetDialog)
int imageIndex = GetPageImage(pageId);
dialog->GetBookCtrl()->AddPage(panel, title, !selected, imageIndex);
selected = true;
-
+
dialog->AddPageId(pageId);
}
}
title = _("Bullets");
return page;
}
+#ifndef __DMC__
+ else if (page == wxRICHTEXT_FORMAT_LIST_STYLE)
+ {
+ wxRichTextListStylePage* page = new wxRichTextListStylePage(dialog->GetBookCtrl(), wxID_ANY);
+ title = _("List Style");
+ return page;
+ }
+#endif
else
return NULL;
}
wxRICHTEXT_FORMAT_FONT,
wxRICHTEXT_FORMAT_INDENTS_SPACING,
wxRICHTEXT_FORMAT_BULLETS,
- wxRICHTEXT_FORMAT_TABS };
+ wxRICHTEXT_FORMAT_TABS,
+ wxRICHTEXT_FORMAT_LIST_STYLE };
- if (i < 0 || i > 4)
+ if (i < 0 || i > 5)
return -1;
return pages[i];
/// Get the number of available page identifiers
int wxRichTextFormattingDialogFactory::GetPageIdCount() const
{
+#ifdef __DMC__
return 5;
+#else
+ return 6;
+#endif
}
/// Set the sheet style, called at the start of wxRichTextFormattingDialog::Create
// If using a toolbook, also follow Mac style and don't create buttons
int flags = wxOK|wxCANCEL;
#ifndef __WXWINCE__
- flags |= wxHELP;
+ if (dialog->GetWindowStyleFlag() & wxRICHTEXT_FORMAT_HELP_BUTTON)
+ flags |= wxHELP;
#endif
if (!useToolBook)
/// Updates the font list
void wxRichTextFontListBox::UpdateFonts()
{
- wxFontEnumerator enumerator;
- enumerator.EnumerateFacenames();
- wxArrayString facenames = enumerator.GetFacenames();
+ wxArrayString facenames = wxRichTextCtrl::GetAvailableFontNames();
m_faceNames = facenames;
m_faceNames.Sort();