Class: MyConfig

Inherits:
Gtk::Table
  • Object
show all
Defined in:
lib/MyConfig.rb

Overview

this file is part of manqod manqod is distributed under the CDDL licence the author of manqod is Dobai-Pataky Balint([email protected])

Defined Under Namespace

Classes: ConfComboHolder, ConfFontHolder

Instance Method Summary collapse

Constructor Details

#initializeMyConfig

Returns a new instance of MyConfig.



53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# File 'lib/MyConfig.rb', line 53

def initialize
	super(2,4)
	@items=Array.new
	@items.push(ConfComboHolder.new("Button size","button-size",{"gtk-button"=>"Button","gtk-dialog" => "Dialog", "gtk-dnd" => "Dnd","gtk-large-toolbar"=>"Large Toolbar","gtk-menu"=>"Menu","gtk-small-toolbar"=>"Small Toolbar"}))
	@items.push(ConfComboHolder.new("List image size","list-image-size",{"gtk-button"=>"Button","gtk-dialog" => "Dialog", "gtk-dnd" => "Dnd","gtk-large-toolbar"=>"Large Toolbar","gtk-menu"=>"Menu","gtk-small-toolbar"=>"Small Toolbar"}))
	@items.push(ConfComboHolder.new("Grid in Lists in Forms","form-grid",{"both"=>"Both","vertical"=>"Vertical","horizontal"=>"Horizontal","none"=>"None"}))
	@items.push(ConfComboHolder.new("Grid in Lists","grid",{"both"=>"Both","vertical"=>"Vertical","horizontal"=>"Horizontal","none"=>"None"}))
	@items.push(ConfComboHolder.new("Tooltip in Lists","list-tooltip",{"none"=>"None","filters"=>"Filters"}))
	@items.push(ConfComboHolder.new("Menu Position","menu-position",{"top"=>"Top","bottom"=>"Bottom","left"=>"Left","right"=>"Right"}))
	@items.push(ConfComboHolder.new("Menu Type","menu-type",{"buttons"=>"Buttons","standard"=>"Standard"}))
	@items.push(ConfComboHolder.new("Confirm Exit","confirm-exit",{"true"=>"Confirm","false"=>"Just exit"}))
	
	@items.push(ConfFontHolder.new("Info Frame Font","info-frame-font"))
	@items.push(ConfFontHolder.new("Info Item Font","info-item-font"))

	@items.push(ConfFontHolder.new("Form Frame Font","form-frame-font"))
	@items.push(ConfFontHolder.new("Form Item Font","form-item-font"))

	@items.push(ConfFontHolder.new("List Button Font","list-button-font"))
	@items.push(ConfFontHolder.new("List Cell Font","list-cell-font"))
	@items.push(ConfFontHolder.new("Standard Menu Font","bar-menu-font"))

	y=0
	@items.each{|item|
		attach(item,0,1,y,y+1,Gtk::EXPAND|Gtk::FILL,Gtk::EXPAND)
		y+=1
	}
	
	show_all
end

Instance Method Details

#titleObject



89
90
91
# File 'lib/MyConfig.rb', line 89

def title
	"Config"
end

#update(notifier = nil) ⇒ Object



85
86
87
# File 'lib/MyConfig.rb', line 85

def update(notifier=nil)
	@items.each{|item| item.update}
end