31 #include "../../../se/Config.h" 
   32 #include "../../../se/Mark.h" 
   38 #include <QtGui/QDialog> 
   39 #include <QtGui/QGridLayout> 
   40 #include <QtGui/QScrollArea> 
   41 #include <QtGui/QPushButton> 
   43 #include "../../../../../third-party/qt/propertybrowser/qtpropertybrowser.h" 
   50   m_mark(new te::se::Mark), m_update(false)
 
   65   addProperty(glyphProperty, tr(
"Glyph Mark"), QColor(175, 175, 255));
 
   85   m_mark = mark->
clone();
 
   92   return m_mark->
clone();
 
   97   const std::string* name = m_mark->getWellKnownName();
 
  100   QString qName(name->c_str());
 
  112   QFont font(fontName);
 
  114   int intCharCode = charCode.unicode();
 
  116   strCharCode.setNum(intCharCode);
 
  127     m_basicFill->setFill(fill);
 
  138   m_mark->setWellKnownName(
new std::string(name.toStdString()));
 
  146   if(m_fontProperty == p )
 
  152   if(m_charProperty == p)
 
  158   if(prop == m_charProperty)
 
  162     connect(m_charDlg, SIGNAL(showDlg()), 
this, SLOT(showCharMapDlg()));
 
  173   QGridLayout* l = 
new QGridLayout(&d);
 
  174   l->setObjectName(
"mainLayout");
 
  175   QScrollArea* sa = 
new QScrollArea(&d);
 
  176   sa->setFixedSize(300, 200);
 
  177   QGridLayout* lsa = 
new QGridLayout(&d);
 
  178   lsa->setObjectName(
"scrollAreaLayout");
 
  183   l->addWidget(sa,0, 0, 1, 2);
 
  184   connect(cmw, SIGNAL(charSelected(
const unsigned int&)), 
this, SLOT(charMapSelected(
const unsigned int&)));
 
  188   QSpacerItem* spacer = 
new QSpacerItem(16, 16, QSizePolicy::MinimumExpanding, QSizePolicy::Minimum);
 
  189   l->addItem(spacer, 1, 0);
 
  190   QPushButton* pb = 
new QPushButton(tr(
"Close"), &d);
 
  191   connect(pb, SIGNAL(clicked()), &d, SLOT(close()));
 
  192   l->addWidget(pb, 1, 1);
 
  193   l->setSizeConstraint(QLayout::SetFixedSize);
 
  196   d.setWindowTitle(tr(
"Char Map"));
 
  197   d.setWindowFlags(Qt::Tool);
 
  216   str.setNum(charCode);
 
  225   m_mark->setFill(m_basicFill->getFill());
 
A Fill specifies the pattern for filling an area geometry. 
 
void setMark(const te::se::Mark *mark)
Sets a mark element to this widget. 
 
te::se::Fill * getFill() const 
 
A concrete renderer based on Qt4 for conversion of Symbology Enconding Mark elements to an image patt...
 
QtStringPropertyManager * m_strDlgManager
 
virtual void valueChanged(QtProperty *p, const QFont &value)
 
te::se::Mark * getMark() const 
Gets the configured mark element. 
 
Mark * clone() const 
It creates a new copy of this object. 
 
A widget used to show the set of characters of a specified font. 
 
te::se::Mark * m_mark
Mark element that will be configured by this widget. 
 
void charMapSelected(const unsigned int &charCode)
 
A widget used to define the basic fill se object. 
 
void setDlg(QWidget *parent, QtProperty *prop)
 
static QString encode(const QString &font, const int &charCode)
Encodes the given parameters to a format known by this renderer. 
 
QtProperty * m_fontProperty
 
void updateUi()
Updates the widget form based on internal mark element. 
 
GlyphMarkPropertyItem(QtTreePropertyBrowser *pb, QColor c=QColor())
Constructor. 
 
te::qt::widgets::BasicFillPropertyItem * m_basicFill
 
QtProperty * m_charProperty
 
~GlyphMarkPropertyItem()
Destructor. 
 
A widget used to define a glyph object. 
 
void updateMarkName()
Updates the mark well-known name enconding selected font and selected character. 
 
QtFontPropertyManager * m_fontManager
 
A widget used to define the main property items that can be used to describe a se object...
 
A widget used to show the set of characters of a specified font. 
 
void addProperty(QtProperty *property, const QString &id, QColor c)
 
static AbstractPropertyManager & getInstance()
It returns a reference to the singleton instance. 
 
static void decode(QString &name, QString &font, QChar &charCode)
Decodes the given name extracting the parameters known by this renderer. 
 
A widget used to define the basic fill se object. 
 
A Mark specifies a geometric shape and applies coloring to it.