9.0 User Interface Tips
[9.1] Use icons in toolbars
Custom toolbar titles and labels are usually text. It is an undocumented feature of the 89/92+ that you
can also use small graphics (icons) in place of the toolbar titles and labels. This code extract shows the
method:
circ()
Prgm
ClrIO
Toolbar
Title circimg
Item radimg,r
Item areaimg,a
Item circimg,c
EndTBar
Lbl r
...
Lbl a
...
Lbl c
...
EndPrgm
In this example, the icons are the variables circimg, radimg, and areaimg. Note that the icon circimg is
used in both the toolbar title, and in the third menu item. The icons are PIC variables, 16 pixels high by
16 pixels wide.
The icons can be created in a number of ways. You can use the pixel functions: PxlCrcl, PxlLine,
PxlOn and PxlText in a program to create the image, then use StoPic to save the image. This program
creates an icon, and saves it as icon1.
iconex()
Prgm
©Create & save a simple icon
©Clear the graph screen
clrgraph
clrdraw
©Draw a box
pxlline 1,1,1,16
pxlline 1,16,16,16
pxlline 16,16,16,1
pxlline 16,1,1,1
©Draw a circle in the box
pxlcrcl 8,8,6
©Draw an "E" in the circle
pxltext "E",5,5
9 - 1
Summary of Contents for TI-92+
Page 52: ...Component side of PCB GraphLink I O connector detail 1 41...
Page 53: ...LCD connector detail PCB switch side 1 42...
Page 54: ...Key pad sheet contact side Key pad sheet key side 1 43...
Page 55: ...Key cap detail 1 44...
Page 57: ...Component side of PCB with shield removed A detail view of the intergrated circuits 1 46...
Page 410: ...void extensionroutine2 void Credit to Bhuvanesh Bhatt 10 4...