Charles.Forsyth20060303-partialeea662d19 years agoHistory
74 lines · 1.6 KB · Text
RawDownload
.TH TABS 2.SH NAMEtabs: mktabs, tabsctl \-tabbed notebook pseudo-widget.SH SYNOPSIS.EXinclude "tabs.m";tabs := load Tabs Tabs->PATH; init:        fn(); mktabs:      fn(p: ref Tk->Toplevel, book: string,               tabs: array of (string, string), dflt: int):               chan of string; tabsctl:     fn(p: ref Tk->Toplevel, book: string,               tabs: array of (string, string), curid: int,               newid: string): int;.EE.SH DESCRIPTION.B Tabsimplements a Tk extension:a user-interface device that looks like a tabbed notebook..PP.B Initshould be called once to initialise the internal state..PP.B Mktabscreates a tabbed notebook pseudo widget,.IR book ,for insertion into Tkwidget.IR p .Once created,.I bookcan be packed like any other Tk widget.Information for specific tab pages is contained in the.I tabsarray.For each page, .I tabscontains the name displayed in the tab and a Tk widget name.Whenever a page is selected, its widget ispacked in .I bookand displayed.The notebook will initially display the pageindexed by.IR dflt ..B Mktabsreturns a Tk event channel.Messages received on this channel should be passed as the.I newidargument to.BR tabsctl ..PP.B Tabsctlcontrols a tabbed notebook..I Curidis the index of the page currently selectedin the notebook..I Newidis a string containing the index of the newpage to be displayed; this is usually the information received onthe tabs channel.The index of the newly selected page is returned. .SH SOURCE.B /appl/lib/tabs.b.SH SEE ALSO.IR dividers (2),.IR draw-context (2),.IR tk (2),.IR wmlib (2)