diff options
author | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-10-22 22:17:08 +0000 |
---|---|---|
committer | nagai <nagai@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-10-22 22:17:08 +0000 |
commit | 3dd3b2136b0050c669d0881ae804b1fae8ea6567 (patch) | |
tree | c2a856bc39c824fe9c2a549d412935b568340956 /ext/tk/lib/tkextlib/iwidgets | |
parent | d6837060becd0cb4586eca08515fc4ee6c8bb2f0 (diff) | |
download | ruby-3dd3b2136b0050c669d0881ae804b1fae8ea6567.tar.gz |
* ext/tk/extconf.rb: improbe messages [ruby-core:06325].
* ext/tk/lib/tk.rb, ext/tk/lib/tk/canvas.rb, ext/tk/lib/tk/entry.rb,
ext/tk/lib/tk/frame.rb, ext/tk/lib/tk/image.rb,
ext/tk/lib/tk/itemconfig.rb, ext/tk/lib/tk/labelframe.rb,
ext/tk/lib/tk/listbox.rb, ext/tk/lib/tk/menu.rb,
ext/tk/lib/tk/radiobutton.rb, ext/tk/lib/tk/scale.rb,
ext/tk/lib/tk/spinbox.rb, ext/tk/lib/tk/text.rb,
ext/tk/lib/tk/toplevel.rb: improve conversion of option values.
* ext/tk/lib/tkextlib/*: ditto.
* ext/tk/lib/tkextlib/*: update to support ActiveTcl8.4.11.2.
* ext/tk/lib/tkextlib/trofs/*: support Trofs 0.4.3.
* ext/tk/lib/tkextlib/tile/*: support Tile 0.7.2.
* ext/tk/lib/tkextlib/vu/*: support vu 2.3.0.
* ext/tk/lib/tkextlib/tcllib/*: support Tcllib 1.8 (Tklib 0.3).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9448 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tk/lib/tkextlib/iwidgets')
40 files changed, 402 insertions, 4 deletions
diff --git a/ext/tk/lib/tkextlib/iwidgets/buttonbox.rb b/ext/tk/lib/tkextlib/iwidgets/buttonbox.rb index 1ff190b9ff..a055e07ac9 100644 --- a/ext/tk/lib/tkextlib/iwidgets/buttonbox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/buttonbox.rb @@ -32,6 +32,11 @@ class Tk::Iwidgets::Buttonbox end private :__item_config_cmd + def __item_boolval_optkeys(id) + super(id) << 'defaultring' + end + private :__item_boolval_optkeys + def tagid(tagOrId) if tagOrId.kind_of?(Tk::Itk::Component) tagOrId.name diff --git a/ext/tk/lib/tkextlib/iwidgets/calendar.rb b/ext/tk/lib/tkextlib/iwidgets/calendar.rb index 97688bb7d0..0152f8593a 100644 --- a/ext/tk/lib/tkextlib/iwidgets/calendar.rb +++ b/ext/tk/lib/tkextlib/iwidgets/calendar.rb @@ -18,6 +18,24 @@ class Tk::Iwidgets::Calendar WidgetClassName = 'Calendar'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() + [ + 'buttonforeground', 'outline', 'selectcolor', + 'weekdaybackground', 'weekendbackground' + ] + end + private :__strval_optkeys + + def __listval_optkeys + super() << 'days' + end + private :__listval_optkeys + + def __font_optkeys + super() + ['currentdatefont', 'datefont', 'dayfont', 'titlefont'] + end + private :__font_optkeys + #################################### include Tk::ValidateConfigure diff --git a/ext/tk/lib/tkextlib/iwidgets/canvasprintbox.rb b/ext/tk/lib/tkextlib/iwidgets/canvasprintbox.rb index 1e2a476591..fa5e90ad05 100644 --- a/ext/tk/lib/tkextlib/iwidgets/canvasprintbox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/canvasprintbox.rb @@ -18,6 +18,16 @@ class Tk::Iwidgets::Canvasprintbox WidgetClassName = 'Canvasprintbox'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'filename' + end + private :__strval_optkeys + + def __boolval_optkeys + super() << 'stretch' + end + private :__boolval_optkeys + def get_output tk_call(@path, 'getoutput') end diff --git a/ext/tk/lib/tkextlib/iwidgets/checkbox.rb b/ext/tk/lib/tkextlib/iwidgets/checkbox.rb index 05d0e1d813..abd23299a8 100644 --- a/ext/tk/lib/tkextlib/iwidgets/checkbox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/checkbox.rb @@ -32,6 +32,11 @@ class Tk::Iwidgets::Checkbox end private :__item_config_cmd + def __item_boolval_optkeys(id) + super(id) << 'defaultring' + end + private :__item_boolval_optkeys + def tagid(tagOrId) if tagOrId.kind_of?(Tk::Itk::Component) tagOrId.name diff --git a/ext/tk/lib/tkextlib/iwidgets/combobox.rb b/ext/tk/lib/tkextlib/iwidgets/combobox.rb index 1cf10b4004..a6d54d78fa 100644 --- a/ext/tk/lib/tkextlib/iwidgets/combobox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/combobox.rb @@ -18,6 +18,11 @@ class Tk::Iwidgets::Combobox WidgetClassName = 'Combobox'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'completion' << 'dropdown' << 'editable' << 'unique' + end + private :__boolval_optkeys + def clear(component=None) tk_call(@path, 'clear', component) self diff --git a/ext/tk/lib/tkextlib/iwidgets/datefield.rb b/ext/tk/lib/tkextlib/iwidgets/datefield.rb index 924aef9c4d..632f3334dc 100644 --- a/ext/tk/lib/tkextlib/iwidgets/datefield.rb +++ b/ext/tk/lib/tkextlib/iwidgets/datefield.rb @@ -18,6 +18,21 @@ class Tk::Iwidgets::Datefield WidgetClassName = 'Datefield'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'gmt' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'textbackground' + end + private :__strval_optkeys + + def __font_optkeys + super() << 'textfont' + end + private :__font_optkeys + def get_string tk_call(@path, 'get', '-string') end diff --git a/ext/tk/lib/tkextlib/iwidgets/dialogshell.rb b/ext/tk/lib/tkextlib/iwidgets/dialogshell.rb index 88b9a97094..d6c668621d 100644 --- a/ext/tk/lib/tkextlib/iwidgets/dialogshell.rb +++ b/ext/tk/lib/tkextlib/iwidgets/dialogshell.rb @@ -32,6 +32,11 @@ class Tk::Iwidgets::Dialogshell end private :__item_config_cmd + def __item_boolval_optkeys(id) + super(id) << 'defaultring' + end + private :__item_boolval_optkeys + def tagid(tagOrId) if tagOrId.kind_of?(Tk::Itk::Component) tagOrId.name diff --git a/ext/tk/lib/tkextlib/iwidgets/disjointlistbox.rb b/ext/tk/lib/tkextlib/iwidgets/disjointlistbox.rb index 8418467925..9bc063ba69 100644 --- a/ext/tk/lib/tkextlib/iwidgets/disjointlistbox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/disjointlistbox.rb @@ -18,6 +18,11 @@ class Tk::Iwidgets::Disjointlistbox WidgetClassName = 'Disjointlistbox'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'lhslabeltext' << 'rhslabeltext' << 'lhsbuttonlabel' << 'rhsbuttonlabel' + end + private :__strval_optkeys + def set_lhs(*items) tk_call(@path, 'setlhs', items) self diff --git a/ext/tk/lib/tkextlib/iwidgets/entryfield.rb b/ext/tk/lib/tkextlib/iwidgets/entryfield.rb index 7a54b7c803..6aa933ce06 100644 --- a/ext/tk/lib/tkextlib/iwidgets/entryfield.rb +++ b/ext/tk/lib/tkextlib/iwidgets/entryfield.rb @@ -18,6 +18,11 @@ class Tk::Iwidgets::Entryfield WidgetClassName = 'Entryfield'.freeze WidgetClassNames[WidgetClassName] = self + def __font_optkeys + super() << 'textfont' + end + private :__font_optkeys + #################################### include Tk::ValidateConfigure diff --git a/ext/tk/lib/tkextlib/iwidgets/extbutton.rb b/ext/tk/lib/tkextlib/iwidgets/extbutton.rb index 7b1e35aa2d..158d9d474a 100644 --- a/ext/tk/lib/tkextlib/iwidgets/extbutton.rb +++ b/ext/tk/lib/tkextlib/iwidgets/extbutton.rb @@ -18,6 +18,16 @@ class Tk::Iwidgets::Extbutton WidgetClassName = 'Extbutton'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'bitmapforeground' << 'ringbackground' + end + private :__strval_optkeys + + def __boolval_optkeys + super() << 'defaultring' + end + private :__boolval_optkeys + def invoke tk_call(@path, 'invoke') self diff --git a/ext/tk/lib/tkextlib/iwidgets/extfileselectionbox.rb b/ext/tk/lib/tkextlib/iwidgets/extfileselectionbox.rb index 282647893c..501f4c90a0 100644 --- a/ext/tk/lib/tkextlib/iwidgets/extfileselectionbox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/extfileselectionbox.rb @@ -18,6 +18,19 @@ class Tk::Iwidgets::Extfileselectionbox WidgetClassName = 'Extfileselectionbox'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() + [ + 'dirslabel', 'fileslabel', 'filterlabel', 'mask', 'nomatchstring', + 'selectionlabel' + ] + end + private :__strval_optkeys + + def __boolval_optkeys + super() + ['dirson', 'fileson', 'filteron', 'selectionon'] + end + private :__boolval_optkeys + def child_site window(tk_call(@path, 'childsite')) end diff --git a/ext/tk/lib/tkextlib/iwidgets/feedback.rb b/ext/tk/lib/tkextlib/iwidgets/feedback.rb index d7439d818a..0a25237a24 100644 --- a/ext/tk/lib/tkextlib/iwidgets/feedback.rb +++ b/ext/tk/lib/tkextlib/iwidgets/feedback.rb @@ -18,6 +18,11 @@ class Tk::Iwidgets::Feedback WidgetClassName = 'Feedback'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'barcolor' + end + private :__strval_optkeys + def reset tk_call(@path, 'reset') self diff --git a/ext/tk/lib/tkextlib/iwidgets/fileselectionbox.rb b/ext/tk/lib/tkextlib/iwidgets/fileselectionbox.rb index 46de13d1b2..7b331d0b40 100644 --- a/ext/tk/lib/tkextlib/iwidgets/fileselectionbox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/fileselectionbox.rb @@ -18,6 +18,19 @@ class Tk::Iwidgets::Fileselectionbox WidgetClassName = 'Fileselectionbox'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() + [ + 'directory', 'dirslabel', 'fileslabel', 'filterlabel', 'mask', + 'nomatchstring', 'selectionlabel' + ] + end + private :__strval_optkeys + + def __boolval_optkeys + super() + ['dirson', 'fileson', 'filteron', 'selectionon'] + end + private :__boolval_optkeys + def child_site window(tk_call(@path, 'childsite')) end diff --git a/ext/tk/lib/tkextlib/iwidgets/finddialog.rb b/ext/tk/lib/tkextlib/iwidgets/finddialog.rb index a161c3c2a4..75e219c37e 100644 --- a/ext/tk/lib/tkextlib/iwidgets/finddialog.rb +++ b/ext/tk/lib/tkextlib/iwidgets/finddialog.rb @@ -18,6 +18,19 @@ class Tk::Iwidgets::Finddialog WidgetClassName = 'Finddialog'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() + [ + 'patternbackground', 'patternforeground', + 'searchbackground', 'searchforeground' + ] + end + private :__strval_optkeys + + def __val2ruby_optkeys # { key=>proc, ... } + super().update('textwidget'=>proc{|v| window(v)}) + end + private :__val2ruby_optkeys + def clear tk_call(@path, 'clear') self diff --git a/ext/tk/lib/tkextlib/iwidgets/hierarchy.rb b/ext/tk/lib/tkextlib/iwidgets/hierarchy.rb index 862876ee9f..4cc6aeecbd 100644 --- a/ext/tk/lib/tkextlib/iwidgets/hierarchy.rb +++ b/ext/tk/lib/tkextlib/iwidgets/hierarchy.rb @@ -101,6 +101,21 @@ class Tk::Iwidgets::Hierarchy #################################### + def __boolval_optkeys + super() << 'alwaysquery' << 'expanded' << 'filter' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'markbackground' << 'markforeground' << 'textbackground' + end + private :__strval_optkeys + + def __font_optkeys + super() << 'textfont' + end + private :__font_optkeys + def clear tk_call(@path, 'clear') self diff --git a/ext/tk/lib/tkextlib/iwidgets/hyperhelp.rb b/ext/tk/lib/tkextlib/iwidgets/hyperhelp.rb index 22e86339a6..77b0e090cd 100644 --- a/ext/tk/lib/tkextlib/iwidgets/hyperhelp.rb +++ b/ext/tk/lib/tkextlib/iwidgets/hyperhelp.rb @@ -18,6 +18,16 @@ class Tk::Iwidgets::Hyperhelp WidgetClassName = 'Hyperhelp'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'helpdir' + end + private :__strval_optkeys + + def __listval_optkeys + super() << 'topics' + end + private :__listval_optkeys + def show_topic(topic) tk_call(@path, 'showtopic', topic) self diff --git a/ext/tk/lib/tkextlib/iwidgets/labeledframe.rb b/ext/tk/lib/tkextlib/iwidgets/labeledframe.rb index 363047018f..e77e85045d 100644 --- a/ext/tk/lib/tkextlib/iwidgets/labeledframe.rb +++ b/ext/tk/lib/tkextlib/iwidgets/labeledframe.rb @@ -18,11 +18,21 @@ class Tk::Iwidgets::Labeledframe WidgetClassName = 'Labeledframe'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'labeltext' + end + private :__strval_optkeys + def __tkvariable_optkeys super() << 'labelvariable' end private :__tkvariable_optkeys + def __font_optkeys + super() << 'labelfont' + end + private :__font_optkeys + def child_site window(tk_call(@path, 'childsite')) end diff --git a/ext/tk/lib/tkextlib/iwidgets/labeledwidget.rb b/ext/tk/lib/tkextlib/iwidgets/labeledwidget.rb index cbd5fa0957..99387710cb 100644 --- a/ext/tk/lib/tkextlib/iwidgets/labeledwidget.rb +++ b/ext/tk/lib/tkextlib/iwidgets/labeledwidget.rb @@ -20,11 +20,21 @@ class Tk::Iwidgets::Labeledwidget WidgetClassName = 'Labeledwidget'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'labeltext' + end + private :__strval_optkeys + def __tkvariable_optkeys super() << 'labelvariable' end private :__tkvariable_optkeys + def __font_optkeys + super() << 'labelfont' + end + private :__font_optkeys + def self.alignlabels(*wins) tk_call('::iwidgets::Labeledwidget::alignlabels', *wins) end diff --git a/ext/tk/lib/tkextlib/iwidgets/mainwindow.rb b/ext/tk/lib/tkextlib/iwidgets/mainwindow.rb index 4570afc6d0..4b2541b997 100644 --- a/ext/tk/lib/tkextlib/iwidgets/mainwindow.rb +++ b/ext/tk/lib/tkextlib/iwidgets/mainwindow.rb @@ -18,6 +18,21 @@ class Tk::Iwidgets::Mainwindow WidgetClassName = 'Mainwindow'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'helpline' << 'statusline' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'menubarbackground' << 'menubarforeground' << 'toolbarforeground' + end + private :__strval_optkeys + + def __font_optkeys + super() << 'menubarfont' << 'toolbarfont' + end + private :__font_optkeys + def child_site window(tk_call(@path, 'childsite')) end diff --git a/ext/tk/lib/tkextlib/iwidgets/menubar.rb b/ext/tk/lib/tkextlib/iwidgets/menubar.rb index ba4bb5f40d..dea3d34c2a 100644 --- a/ext/tk/lib/tkextlib/iwidgets/menubar.rb +++ b/ext/tk/lib/tkextlib/iwidgets/menubar.rb @@ -18,6 +18,11 @@ class Tk::Iwidgets::Menubar WidgetClassName = 'Menubar'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'menubuttons' + end + private :__strval_optkeys + def __tkvariable_optkeys super() << 'helpvariable' end @@ -37,6 +42,16 @@ class Tk::Iwidgets::Menubar end private :__item_config_cmd + def __item_strval_optkeys(id) + super(id) << 'selectcolor' + end + private :__item_strval_optkeys + + def __item_tkvariable_optkeys(id) + super(id) << 'helpstr' + end + private :__item_tkvariable_optkeys + def tagid(tagOrId) if tagOrId.kind_of?(Tk::Itk::Component) tagOrId.name diff --git a/ext/tk/lib/tkextlib/iwidgets/messagebox.rb b/ext/tk/lib/tkextlib/iwidgets/messagebox.rb index 608f6f7adb..2bbbec7666 100644 --- a/ext/tk/lib/tkextlib/iwidgets/messagebox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/messagebox.rb @@ -41,6 +41,11 @@ class Tk::Iwidgets::Messagebox end end + def __item_boolval_optkeys(id) + super(id) << 'bell' << 'show' + end + private :__item_boolval_optkeys + alias typecget itemcget alias typeconfigure itemconfigure alias typeconfiginfo itemconfiginfo @@ -51,6 +56,11 @@ class Tk::Iwidgets::Messagebox #################################### + def __strval_optkeys + super() << 'filename' << 'savedir' + end + private :__strval_optkeys + def type_add(tag=nil, keys={}) if tag.kind_of?(Hash) keys = tag diff --git a/ext/tk/lib/tkextlib/iwidgets/notebook.rb b/ext/tk/lib/tkextlib/iwidgets/notebook.rb index 4df56cce7f..0f9d713ea1 100644 --- a/ext/tk/lib/tkextlib/iwidgets/notebook.rb +++ b/ext/tk/lib/tkextlib/iwidgets/notebook.rb @@ -23,12 +23,12 @@ class Tk::Iwidgets::Notebook include TkItemConfigMethod def __item_cget_cmd(id) - [self.path, 'tabcget', id] + [self.path, 'pagecget', id] end private :__item_cget_cmd def __item_config_cmd(id) - [self.path, 'tabconfigure', id] + [self.path, 'pageconfigure', id] end private :__item_config_cmd @@ -51,6 +51,11 @@ class Tk::Iwidgets::Notebook #################################### + def __boolval_optkeys + super() << 'auto' + end + private :__boolval_optkeys + def add(keys={}) window(tk_call(@path, 'add', *hash_kv(keys))) end diff --git a/ext/tk/lib/tkextlib/iwidgets/optionmenu.rb b/ext/tk/lib/tkextlib/iwidgets/optionmenu.rb index 226163a150..0c74440be7 100644 --- a/ext/tk/lib/tkextlib/iwidgets/optionmenu.rb +++ b/ext/tk/lib/tkextlib/iwidgets/optionmenu.rb @@ -18,6 +18,11 @@ class Tk::Iwidgets::Optionmenu WidgetClassName = 'Optionmenu'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'cyclicon' + end + private :__boolval_optkeys + def delete(first, last=nil) if last tk_call(@path, 'delete', first, last) diff --git a/ext/tk/lib/tkextlib/iwidgets/panedwindow.rb b/ext/tk/lib/tkextlib/iwidgets/panedwindow.rb index a205036239..035df0a5b8 100644 --- a/ext/tk/lib/tkextlib/iwidgets/panedwindow.rb +++ b/ext/tk/lib/tkextlib/iwidgets/panedwindow.rb @@ -51,6 +51,11 @@ class Tk::Iwidgets::Panedwindow #################################### + def __boolval_optkeys + super() << 'showhandle' + end + private :__boolval_optkeys + def add(tag=nil, keys={}) if tag.kind_of?(Hash) keys = tag diff --git a/ext/tk/lib/tkextlib/iwidgets/pushbutton.rb b/ext/tk/lib/tkextlib/iwidgets/pushbutton.rb index 25d3633507..c21007ca6c 100644 --- a/ext/tk/lib/tkextlib/iwidgets/pushbutton.rb +++ b/ext/tk/lib/tkextlib/iwidgets/pushbutton.rb @@ -18,6 +18,11 @@ class Tk::Iwidgets::Pushbutton WidgetClassName = 'Pushbutton'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'defaultring' + end + private :__boolval_optkeys + def invoke tk_call_without_enc(@path, 'invoke') self diff --git a/ext/tk/lib/tkextlib/iwidgets/radiobox.rb b/ext/tk/lib/tkextlib/iwidgets/radiobox.rb index 84c15082d6..d4316754f2 100644 --- a/ext/tk/lib/tkextlib/iwidgets/radiobox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/radiobox.rb @@ -32,6 +32,11 @@ class Tk::Iwidgets::Radiobox end private :__item_config_cmd + def __item_boolval_optkeys(id) + super(id) << 'defaultring' + end + private :__item_boolval_optkeys + def tagid(tagOrId) if tagOrId.kind_of?(Tk::Itk::Component) tagOrId.name diff --git a/ext/tk/lib/tkextlib/iwidgets/scrolledcanvas.rb b/ext/tk/lib/tkextlib/iwidgets/scrolledcanvas.rb index 2a6f3a71b6..407c8f2aad 100644 --- a/ext/tk/lib/tkextlib/iwidgets/scrolledcanvas.rb +++ b/ext/tk/lib/tkextlib/iwidgets/scrolledcanvas.rb @@ -21,6 +21,16 @@ class Tk::Iwidgets::Scrolledcanvas ################################ + def __boolval_optkeys + super() << 'autoresize' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'textbackground' + end + private :__strval_optkeys + def initialize(*args) super(*args) @canvas = component_widget('canvas') diff --git a/ext/tk/lib/tkextlib/iwidgets/scrolledhtml.rb b/ext/tk/lib/tkextlib/iwidgets/scrolledhtml.rb index 7023d889d1..9b69ef07fe 100644 --- a/ext/tk/lib/tkextlib/iwidgets/scrolledhtml.rb +++ b/ext/tk/lib/tkextlib/iwidgets/scrolledhtml.rb @@ -18,6 +18,21 @@ class Tk::Iwidgets::Scrolledhtml WidgetClassName = 'Scrolledhtml'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'update' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'fontname' << 'link' << 'alink' << 'textbackground' + end + private :__strval_optkeys + + def __font_optkeys + super() << 'fixedfont' + end + private :__font_optkeys + def import(href) tk_call(@path, 'import', href) self diff --git a/ext/tk/lib/tkextlib/iwidgets/scrolledlistbox.rb b/ext/tk/lib/tkextlib/iwidgets/scrolledlistbox.rb index c933bf2985..cd1f6f0f79 100644 --- a/ext/tk/lib/tkextlib/iwidgets/scrolledlistbox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/scrolledlistbox.rb @@ -19,11 +19,21 @@ class Tk::Iwidgets::Scrolledlistbox WidgetClassName = 'Scrolledlistbox'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'textbackground' + end + private :__strval_optkeys + def __tkvariable_optkeys super() << 'listvariable' end private :__tkvariable_optkeys + def __font_optkeys + super() << 'textfont' + end + private :__font_optkeys + ################################ def initialize(*args) diff --git a/ext/tk/lib/tkextlib/iwidgets/scrolledtext.rb b/ext/tk/lib/tkextlib/iwidgets/scrolledtext.rb index 8e4162aaf2..fdafc8dc7f 100644 --- a/ext/tk/lib/tkextlib/iwidgets/scrolledtext.rb +++ b/ext/tk/lib/tkextlib/iwidgets/scrolledtext.rb @@ -19,6 +19,16 @@ class Tk::Iwidgets::Scrolledtext WidgetClassName = 'Scrolledtext'.freeze WidgetClassNames[WidgetClassName] = self + def __strval_optkeys + super() << 'textbackground' + end + private :__strval_optkeys + + def __font_optkeys + super() << 'textfont' + end + private :__font_optkeys + ################################ def initialize(*args) diff --git a/ext/tk/lib/tkextlib/iwidgets/selectionbox.rb b/ext/tk/lib/tkextlib/iwidgets/selectionbox.rb index 154a9792da..bb81fcca5e 100644 --- a/ext/tk/lib/tkextlib/iwidgets/selectionbox.rb +++ b/ext/tk/lib/tkextlib/iwidgets/selectionbox.rb @@ -18,6 +18,16 @@ class Tk::Iwidgets::Selectionbox WidgetClassName = 'Selectionbox'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'itemson' << 'selectionon' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'itemslabel' << 'selectionlabel' + end + private :__strval_optkeys + def child_site window(tk_call(@path, 'childsite')) end diff --git a/ext/tk/lib/tkextlib/iwidgets/spindate.rb b/ext/tk/lib/tkextlib/iwidgets/spindate.rb index 6099ba77b9..2c98eb4629 100644 --- a/ext/tk/lib/tkextlib/iwidgets/spindate.rb +++ b/ext/tk/lib/tkextlib/iwidgets/spindate.rb @@ -18,6 +18,16 @@ class Tk::Iwidgets::Spindate WidgetClassName = 'Spindate'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'dayon' << 'monthon' << 'yearon' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'daylabel' << 'monthformat' << 'monthlabel' << 'yearlabel' + end + private :__strval_optkeys + def get_string tk_call(@path, 'get', '-string') end diff --git a/ext/tk/lib/tkextlib/iwidgets/spinint.rb b/ext/tk/lib/tkextlib/iwidgets/spinint.rb index 071b6ab8f7..5eb944d081 100644 --- a/ext/tk/lib/tkextlib/iwidgets/spinint.rb +++ b/ext/tk/lib/tkextlib/iwidgets/spinint.rb @@ -17,4 +17,14 @@ class Tk::Iwidgets::Spinint TkCommandNames = ['::iwidgets::spinint'.freeze].freeze WidgetClassName = 'Spinint'.freeze WidgetClassNames[WidgetClassName] = self + + def __boolval_optkeys + super() << 'wrap' + end + private :__boolval_optkeys + + def __numlistval_optkeys + super() << 'range' + end + private :__numlistval_optkeys end diff --git a/ext/tk/lib/tkextlib/iwidgets/spintime.rb b/ext/tk/lib/tkextlib/iwidgets/spintime.rb index c1e1f5e5f1..0ff683ab56 100644 --- a/ext/tk/lib/tkextlib/iwidgets/spintime.rb +++ b/ext/tk/lib/tkextlib/iwidgets/spintime.rb @@ -18,6 +18,16 @@ class Tk::Iwidgets::Spintime WidgetClassName = 'Spintime'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'houron' << 'militaryon' << 'minutelabel' << 'secondlabel' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'hourlabel' << 'minuteon' << 'secondon' + end + private :__strval_optkeys + def get_string tk_call(@path, 'get', '-string') end diff --git a/ext/tk/lib/tkextlib/iwidgets/tabnotebook.rb b/ext/tk/lib/tkextlib/iwidgets/tabnotebook.rb index 5321331551..0d9715f87b 100644 --- a/ext/tk/lib/tkextlib/iwidgets/tabnotebook.rb +++ b/ext/tk/lib/tkextlib/iwidgets/tabnotebook.rb @@ -23,15 +23,20 @@ class Tk::Iwidgets::Tabnotebook include TkItemConfigMethod def __item_cget_cmd(id) - [self.path, 'tabcget', id] + [self.path, 'pagecget', id] end private :__item_cget_cmd def __item_config_cmd(id) - [self.path, 'tabconfigure', id] + [self.path, 'pageconfigure', id] end private :__item_config_cmd + def __item_strval_optkeys(id) + super(id) << 'tabbackground' << 'tabforeground' + end + private :__item_strval_optkeys + def tagid(tagOrId) if tagOrId.kind_of?(Tk::Itk::Component) tagOrId.name @@ -51,6 +56,16 @@ class Tk::Iwidgets::Tabnotebook #################################### + def __boolval_optkeys + super() << 'auto' << 'equaltabs' << 'raiseselect' << 'tabborders' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'backdrop' << 'tabbackground' << 'tabforeground' + end + private :__strval_optkeys + def initialize(*args) super(*args) @tabset = self.component_widget('tabset') diff --git a/ext/tk/lib/tkextlib/iwidgets/tabset.rb b/ext/tk/lib/tkextlib/iwidgets/tabset.rb index 1b76916ab7..54e56d0514 100644 --- a/ext/tk/lib/tkextlib/iwidgets/tabset.rb +++ b/ext/tk/lib/tkextlib/iwidgets/tabset.rb @@ -51,6 +51,16 @@ class Tk::Iwidgets::Tabset #################################### + def __boolval_optkeys + super() << 'equaltabs' << 'raiseselect' << 'tabborders' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'backdrop' + end + private :__strval_optkeys + def add(keys={}) window(tk_call(@path, 'add', *hash_kv(keys))) end diff --git a/ext/tk/lib/tkextlib/iwidgets/timeentry.rb b/ext/tk/lib/tkextlib/iwidgets/timeentry.rb index 987cddc1e0..588da77dc8 100644 --- a/ext/tk/lib/tkextlib/iwidgets/timeentry.rb +++ b/ext/tk/lib/tkextlib/iwidgets/timeentry.rb @@ -17,4 +17,9 @@ class Tk::Iwidgets::Timeentry TkCommandNames = ['::iwidgets::timeentry'.freeze].freeze WidgetClassName = 'Timeentry'.freeze WidgetClassNames[WidgetClassName] = self + + def __strval_optkeys + super() << 'closetext' + end + private :__strval_optkeys end diff --git a/ext/tk/lib/tkextlib/iwidgets/timefield.rb b/ext/tk/lib/tkextlib/iwidgets/timefield.rb index 602093eb7e..28e1504797 100644 --- a/ext/tk/lib/tkextlib/iwidgets/timefield.rb +++ b/ext/tk/lib/tkextlib/iwidgets/timefield.rb @@ -18,6 +18,21 @@ class Tk::Iwidgets::Timefield WidgetClassName = 'Timefield'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'gmt' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'textbackground' + end + private :__strval_optkeys + + def __font_optkeys + super() << 'textfont' + end + private :__font_optkeys + def get_string tk_call(@path, 'get', '-string') end diff --git a/ext/tk/lib/tkextlib/iwidgets/toolbar.rb b/ext/tk/lib/tkextlib/iwidgets/toolbar.rb index 74bb0cc96c..17cfa62156 100644 --- a/ext/tk/lib/tkextlib/iwidgets/toolbar.rb +++ b/ext/tk/lib/tkextlib/iwidgets/toolbar.rb @@ -37,6 +37,11 @@ class Tk::Iwidgets::Toolbar end private :__item_config_cmd + def __item_strval_optkeys(id) + super(id) << 'helpstr' << 'balloonstr' + end + private :__item_strval_optkeys + def tagid(tagOrId) if tagOrId.kind_of?(Tk::Itk::Component) tagOrId.name @@ -48,6 +53,21 @@ class Tk::Iwidgets::Toolbar #################################### + def __strval_optkeys + super() << 'balloonbackground' << 'balloonforeground' + end + private :__strval_optkeys + + def __tkvariable_optkeys + super() << 'helpvariable' + end + private :__tkvariable_optkeys + + def __font_optkeys + super() << 'balloonfont' + end + private :__font_optkeys + def add(type, tag=nil, keys={}) if tag.kind_of?(Hash) keys = tag diff --git a/ext/tk/lib/tkextlib/iwidgets/watch.rb b/ext/tk/lib/tkextlib/iwidgets/watch.rb index f62c0b931e..ab2b687cf9 100644 --- a/ext/tk/lib/tkextlib/iwidgets/watch.rb +++ b/ext/tk/lib/tkextlib/iwidgets/watch.rb @@ -18,6 +18,17 @@ class Tk::Iwidgets::Watch WidgetClassName = 'Watch'.freeze WidgetClassNames[WidgetClassName] = self + def __boolval_optkeys + super() << 'showampm' + end + private :__boolval_optkeys + + def __strval_optkeys + super() << 'clockcolor' << 'hourcolor' << 'minutecolor' << + 'pivotcolor' << 'secondcolor' << 'tickcolor' + end + private :__strval_optkeys + def get_string tk_call(@path, 'get', '-string') end |