2 ** Project : Form Designer
3 ** File Purpose : QLCDNumber Control
5 ** Author : Mahmoud Fayed <msfclipper@yahoo.com>
10 class FormDesigner_QLCDNumber from QLCDNumber
12 CreateCommonAttributes()
13 CreateMoveResizeCornersAttributes()
20 func SetDisplayValue nValue
24 func AddObjectProperties oDesigner
25 AddObjectCommonProperties(oDesigner)
26 oDesigner.oView.AddProperty(T_FORMDESIGNER_ATTRIBUTE_DISPLAY,False) # "Display"
28 func DisplayProperties oDesigner
29 DisplayCommonProperties(oDesigner)
30 oPropertiesTable = oDesigner.oView.oPropertiesTable
31 oPropertiesTable.Blocksignals(True)
32 # Set the Display Value
33 oPropertiesTable.item(C_AFTERCOMMON,1).settext(""+DisplayValue())
34 oPropertiesTable.Blocksignals(False)
36 func UpdateProperties oDesigner,nRow,nCol,cValue
37 UpdateCommonProperties(oDesigner,nRow,nCol,cValue)
38 if nRow = C_AFTERCOMMON {
39 setDisplayValue(0+cValue)
42 func ObjectDataAsString oDesigner,nTabsCount
43 cOutput = ObjectDataAsString2(oDesigner,nTabsCount)
44 cTabs = std_copy(char(9),nTabsCount)
45 cOutput += "," + nl + cTabs + ' :display = ' + DisplayValue()
48 func GenerateCustomCode oDesigner
49 cOutput = 'Display(#{f1})' + nl
50 cOutput = substr(cOutput,"#{f1}",""+DisplayValue())
53 func RestoreProperties oDesigner,Item
54 RestoreCommonProperties(oDesigner,item)
55 itemdata = item[:data]
56 setDisplayValue(itemdata[:Display])