Skip to content
Permalink
Browse files

Added more functions to function tree

  • Loading branch information
NathanW2 committed Sep 3, 2011
1 parent 72c045a commit c6da52c1bbd5657042328d0e7c122b4be718f466
Showing with 35 additions and 6 deletions.
  1. +21 −1 src/gui/qgsexpressionbuilder.cpp
  2. +14 −5 src/ui/qgslabelingguibase.ui
@@ -2,7 +2,7 @@
qgisexpressionbuilder.cpp - A genric expression string builder widget.
--------------------------------------
Date : 29-May-2011
Copyright : (C) 2006 by Nathan Woodrow
Copyright : (C) 2011 by Nathan Woodrow
Email : nathan.woodrow at gmail dot com
***************************************************************************
* *
@@ -48,6 +48,26 @@ QgsExpressionBuilderWidget::QgsExpressionBuilderWidget(QgsVectorLayer *layer)
this->registerItem("Geometry","Y"," $y ");
this->registerItem("Geometry","XAt"," xat( ");
this->registerItem("Geometry","YAt"," yat( ");

this->registerItem("String","Lower Case"," lower( ");
this->registerItem("String","Upper Case"," upper( ");
this->registerItem("String","Length"," length( ");
this->registerItem("String","Replace"," replace(,,, ");
this->registerItem("String","Regex Replace"," regexp_replace(,,, ");
this->registerItem("String","Substring"," substr(,,, ");

this->registerItem("Math","Square Root"," sqrt( ");
this->registerItem("Math","SIN"," sin( ");
this->registerItem("Math","COS"," cos( ");
this->registerItem("Math","TAN"," tan( ");
this->registerItem("Math","ASIN"," asin( ");
this->registerItem("Math","ACOS"," acos( ");
this->registerItem("Math","ATAN"," atan( ");
this->registerItem("Math","ATAN2"," atan2(, ");

this->registerItem("Casting","To integer"," toint( ");
this->registerItem("Casting","To real"," toreal( ");
this->registerItem("Casting","To string"," tostring( ");
}

QgsExpressionBuilderWidget::~QgsExpressionBuilderWidget()
@@ -38,6 +38,9 @@
</item>
<item>
<widget class="QgsLabelPreview" name="lblFontPreview">
<property name="enabled">
<bool>true</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="MinimumExpanding">
<horstretch>0</horstretch>
@@ -66,7 +69,7 @@
<bool>false</bool>
</property>
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<property name="iconSize">
<size>
@@ -76,7 +79,7 @@
</property>
<widget class="QWidget" name="tab_3">
<attribute name="icon">
<iconset resource="../../images/images.qrc">
<iconset>
<normaloff>:/images/themes/default/propertyicons/labels.png</normaloff>:/images/themes/default/propertyicons/labels.png</iconset>
</attribute>
<attribute name="title">
@@ -387,7 +390,7 @@
</widget>
<widget class="QWidget" name="tab">
<attribute name="icon">
<iconset resource="../../images/images.qrc">
<iconset>
<normaloff>:/images/themes/default/propertyicons/general.png</normaloff>:/images/themes/default/propertyicons/general.png</iconset>
</attribute>
<attribute name="title">
@@ -397,11 +400,17 @@
<item row="0" column="0">
<widget class="QScrollArea" name="scrollArea_2">
<property name="autoFillBackground">
<bool>true</bool>
<bool>false</bool>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Plain</enum>
</property>
<property name="lineWidth">
<number>0</number>
</property>
<property name="widgetResizable">
<bool>true</bool>
</property>
@@ -847,7 +856,7 @@
</widget>
<widget class="QWidget" name="tab_4">
<attribute name="icon">
<iconset resource="../../images/images.qrc">
<iconset>
<normaloff>:/images/themes/gis/mActionOpenTable.png</normaloff>:/images/themes/gis/mActionOpenTable.png</iconset>
</attribute>
<attribute name="title">

0 comments on commit c6da52c

Please sign in to comment.
You can’t perform that action at this time.