Skip to content

Commit c6da52c

Browse files
committedSep 3, 2011
Added more functions to function tree
1 parent 72c045a commit c6da52c

File tree

2 files changed

+35
-6
lines changed

2 files changed

+35
-6
lines changed
 

‎src/gui/qgsexpressionbuilder.cpp

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
qgisexpressionbuilder.cpp - A genric expression string builder widget.
33
--------------------------------------
44
Date : 29-May-2011
5-
Copyright : (C) 2006 by Nathan Woodrow
5+
Copyright : (C) 2011 by Nathan Woodrow
66
Email : nathan.woodrow at gmail dot com
77
***************************************************************************
88
* *
@@ -48,6 +48,26 @@ QgsExpressionBuilderWidget::QgsExpressionBuilderWidget(QgsVectorLayer *layer)
4848
this->registerItem("Geometry","Y"," $y ");
4949
this->registerItem("Geometry","XAt"," xat( ");
5050
this->registerItem("Geometry","YAt"," yat( ");
51+
52+
this->registerItem("String","Lower Case"," lower( ");
53+
this->registerItem("String","Upper Case"," upper( ");
54+
this->registerItem("String","Length"," length( ");
55+
this->registerItem("String","Replace"," replace(,,, ");
56+
this->registerItem("String","Regex Replace"," regexp_replace(,,, ");
57+
this->registerItem("String","Substring"," substr(,,, ");
58+
59+
this->registerItem("Math","Square Root"," sqrt( ");
60+
this->registerItem("Math","SIN"," sin( ");
61+
this->registerItem("Math","COS"," cos( ");
62+
this->registerItem("Math","TAN"," tan( ");
63+
this->registerItem("Math","ASIN"," asin( ");
64+
this->registerItem("Math","ACOS"," acos( ");
65+
this->registerItem("Math","ATAN"," atan( ");
66+
this->registerItem("Math","ATAN2"," atan2(, ");
67+
68+
this->registerItem("Casting","To integer"," toint( ");
69+
this->registerItem("Casting","To real"," toreal( ");
70+
this->registerItem("Casting","To string"," tostring( ");
5171
}
5272

5373
QgsExpressionBuilderWidget::~QgsExpressionBuilderWidget()

‎src/ui/qgslabelingguibase.ui

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@
3838
</item>
3939
<item>
4040
<widget class="QgsLabelPreview" name="lblFontPreview">
41+
<property name="enabled">
42+
<bool>true</bool>
43+
</property>
4144
<property name="sizePolicy">
4245
<sizepolicy hsizetype="Expanding" vsizetype="MinimumExpanding">
4346
<horstretch>0</horstretch>
@@ -66,7 +69,7 @@
6669
<bool>false</bool>
6770
</property>
6871
<property name="currentIndex">
69-
<number>1</number>
72+
<number>0</number>
7073
</property>
7174
<property name="iconSize">
7275
<size>
@@ -76,7 +79,7 @@
7679
</property>
7780
<widget class="QWidget" name="tab_3">
7881
<attribute name="icon">
79-
<iconset resource="../../images/images.qrc">
82+
<iconset>
8083
<normaloff>:/images/themes/default/propertyicons/labels.png</normaloff>:/images/themes/default/propertyicons/labels.png</iconset>
8184
</attribute>
8285
<attribute name="title">
@@ -387,7 +390,7 @@
387390
</widget>
388391
<widget class="QWidget" name="tab">
389392
<attribute name="icon">
390-
<iconset resource="../../images/images.qrc">
393+
<iconset>
391394
<normaloff>:/images/themes/default/propertyicons/general.png</normaloff>:/images/themes/default/propertyicons/general.png</iconset>
392395
</attribute>
393396
<attribute name="title">
@@ -397,11 +400,17 @@
397400
<item row="0" column="0">
398401
<widget class="QScrollArea" name="scrollArea_2">
399402
<property name="autoFillBackground">
400-
<bool>true</bool>
403+
<bool>false</bool>
401404
</property>
402405
<property name="frameShape">
403406
<enum>QFrame::NoFrame</enum>
404407
</property>
408+
<property name="frameShadow">
409+
<enum>QFrame::Plain</enum>
410+
</property>
411+
<property name="lineWidth">
412+
<number>0</number>
413+
</property>
405414
<property name="widgetResizable">
406415
<bool>true</bool>
407416
</property>
@@ -847,7 +856,7 @@
847856
</widget>
848857
<widget class="QWidget" name="tab_4">
849858
<attribute name="icon">
850-
<iconset resource="../../images/images.qrc">
859+
<iconset>
851860
<normaloff>:/images/themes/gis/mActionOpenTable.png</normaloff>:/images/themes/gis/mActionOpenTable.png</iconset>
852861
</attribute>
853862
<attribute name="title">

0 commit comments

Comments
 (0)
Please sign in to comment.