Warning, /frameworks/syntax-highlighting/autotests/input/highlight.prg is written in an unsupported language. File is not indexed.
0001 // Test file to test kate's clipper highlighting
0002 // kate: hl Clipper;
0003
0004 //BEGIN INCLUDES
0005 #include <clip-ui.ch>
0006 #include "logo.ch"
0007
0008 #define PRGVERSION "0.0.1"
0009 //END
0010
0011 //BEGIN CODE
0012 static ws, win
0013 static driver := getDriver()
0014 /* a multiline
0015 comment
0016 */
0017
0018 function main( formName )
0019 local form
0020 local fileName
0021
0022 if empty(formName)
0023 ?? "Usage: ./form_ui <form.xfl>&\n"
0024 CANCEL
0025 else
0026 fileName := formName
0027 endif
0028 ws := UIWorkSpace()
0029
0030 form := UIForm( fileName )
0031 win := form:parseFile()
0032 // ?? valtype(win),chr(10)
0033 if win == NIL
0034 CANCEL
0035 endif
0036 win:show()
0037
0038 ws:run()
0039 ws:quit()
0040 return 0
0041
0042 /* Setting dialog */
0043 function settingsDialog()
0044 ?? "TODO: Settings dialog&\n"
0045 return
0046
0047 /* About dialog */
0048 function aboutDialog()
0049 local dlg := UIWindow("About", win, "aboutDlg", .F.)
0050 local hl, lside, t, bb, bD
0051
0052 hl := UIHBox(,4,8)
0053 lside := UIVBox()
0054 lside:add(UIImage(eas_logo_mini,.T.))
0055 hl:add(lside,.F.,.F.)
0056 dlg:userSpace:add(hl,.T.,.T.)
0057 t := UIVBox()
0058 hl:add(t,.T.,.T.)
0059
0060 t:add(UILabel("License: GPL version 2 or later"))
0061 bb := UIButtonBar()
0062 t:add(bb)
0063 bD := UIButton(win, "&Close", {|o,e| dlg:close() } )
0064 bb:add( bD )
0065
0066 dlg:setFocus(bD)
0067 dlg:setDefault(bD)
0068 dlg:setPlacement( .T. )
0069 dlg:show()
0070 return
0071 //END