OSDN Git Service

Ring 1.10 以来となる開発環境の日本語ローカライズ版 (評価版) を追加 (ノートパッド、フォームデザイナー、対話型実行環境、ファイルの検索)。
[ring-lang-081/ring.git] / applications / build / ja-jp / formdesigner / controls / qlcdnumber.ring
1 /*
2 **      Project : Form Designer 
3 **      File Purpose :  QLCDNumber Control
4 **      Date : 2017.04.29
5 **      Author :  Mahmoud Fayed <msfclipper@yahoo.com>
6 */
7
8 package formdesigner
9
10 class FormDesigner_QLCDNumber from QLCDNumber
11
12         CreateCommonAttributes()
13         CreateMoveResizeCornersAttributes()
14
15         nDisplay  = 0
16
17         func DisplayValue
18                 return nDisplay
19
20         func SetDisplayValue nValue
21                 nDisplay = nValue
22                 Display(nDisplay)
23
24         func AddObjectProperties  oDesigner
25                 AddObjectCommonProperties(oDesigner)
26                 oDesigner.oView.AddProperty(T_FORMDESIGNER_ATTRIBUTE_DISPLAY,False) # "Display"
27
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)
35
36         func UpdateProperties oDesigner,nRow,nCol,cValue
37                 UpdateCommonProperties(oDesigner,nRow,nCol,cValue)
38                 if nRow = C_AFTERCOMMON {
39                         setDisplayValue(0+cValue)
40                 }
41
42         func ObjectDataAsString oDesigner,nTabsCount
43                 cOutput = ObjectDataAsString2(oDesigner,nTabsCount)
44                 cTabs = std_copy(char(9),nTabsCount)
45                 cOutput += "," + nl + cTabs + ' :display =  ' + DisplayValue()
46                 return cOutput
47
48         func GenerateCustomCode oDesigner
49                 cOutput = 'Display(#{f1})' + nl
50                 cOutput = substr(cOutput,"#{f1}",""+DisplayValue())
51                 return cOutput
52
53         func RestoreProperties oDesigner,Item
54                 RestoreCommonProperties(oDesigner,item)
55                 itemdata = item[:data]
56                 setDisplayValue(itemdata[:Display])