fxruby 1.6.22.pre4-x86-mingw32 → 1.6.22-x86-mingw32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/History.txt CHANGED
@@ -1,3 +1,23 @@
1
+
2
+ === 1.6.22 / 2012-02-21
3
+
4
+ * Allow better access to raw pixel data of FXImage and derivatives
5
+ * Build Windows binary gem per cross compiler on Linux
6
+ * Add support for Rubinius (currently requires rubinius from git)
7
+ * Add alias FXApp#modalWindow, as described in rdoc
8
+ * Add quality parameter to FXJPGImage and FXJPGIcon
9
+ * Fix invalid memory access in final GC call when using FXMenuCommand with acckey
10
+ * Fix double referenced foxObj when borrowed object registration is triggered from C++
11
+ * Fix Segfault while GC'ing FXWindows
12
+ * Fix 'object allocation not allowed while garbage collection' bug
13
+ * Fix clipboard handling on windows
14
+ * Add missing namespace qualifier to FXSEL in FXAccelTable
15
+ * Fix GC bug in FXAccelTable
16
+ * Fix double free in FXMemoryStream#giveBuffer
17
+ * Fix invalid memory access in typemap to zero terminated FXchar* (such as fillItems methods)
18
+ * Fix FXApp#addInput for Ruby 1.9 on Linux
19
+ * Fix "ruby_code case not handled: Regexp" issue with newer rubygems
20
+
1
21
  === 1.6.20 / 2009-03-06
2
22
 
3
23
  * Integrated the Hoe and rake-compiler extensions into the Rakefile and
data/Rakefile CHANGED
@@ -46,6 +46,7 @@ Rake::ExtensionTask.new("fox16", hoe.spec) do |ext|
46
46
  ext.cross_compile = true
47
47
  ext.cross_platform = ['i386-mingw32']
48
48
  ext.cross_config_options += [
49
+ "--with-fox-include=#{STATIC_INSTALLDIR}/include/fox-1.6",
49
50
  "--with-fxscintilla-include=#{STATIC_INSTALLDIR}/include/fxscintilla",
50
51
  "--with-installed-dir=#{STATIC_INSTALLDIR}",
51
52
  "--enable-win32-static-build",
data/doap.rdf CHANGED
@@ -77,8 +77,8 @@
77
77
  <doap:release>
78
78
  <doap:Version>
79
79
  <doap:branch>fox16</doap:branch>
80
- <doap:created>2012-02-16</doap:created>
81
- <doap:revision>1.6.22.pre4</doap:revision>
80
+ <doap:created>2012-02-21</doap:created>
81
+ <doap:revision>1.7.0</doap:revision>
82
82
  </doap:Version>
83
83
  </doap:release>
84
84
 
data/examples/bounce.rb CHANGED
@@ -25,7 +25,7 @@ class Ball
25
25
  @x = @center.x - @radius
26
26
  @y = @center.y - @radius
27
27
  @color = FXRGB(255, 0, 0) # red
28
- @dir = FXPoint.new(-1, 0)
28
+ @dir = FXPoint.new(-1, -1)
29
29
  setWorldSize(1000, 1000)
30
30
  end
31
31
 
@@ -38,12 +38,20 @@ class Ball
38
38
  dc.fillArc(x, y, w, h, 64*270, 64*360)
39
39
  end
40
40
 
41
- def bounce
42
- @dir = -@dir
41
+ def bounce_x
42
+ @dir.x=-@dir.x
43
43
  end
44
44
 
45
- def collision?
46
- (x < 0) || (x+w > worldWidth) || (y < 0) || (y+h > worldHeight)
45
+ def bounce_y
46
+ @dir.y=-@dir.y
47
+ end
48
+
49
+ def collision_y?
50
+ (y<0 && dir.y<0) || (y+h>worldHeight && dir.y>0)
51
+ end
52
+
53
+ def collision_x?
54
+ (x<0 && dir.x<0) || (x+w>worldWidth && dir.x>0)
47
55
  end
48
56
 
49
57
  def setWorldSize(ww, wh)
@@ -58,8 +66,12 @@ class Ball
58
66
  center.y += dy
59
67
  @x += dx
60
68
  @y += dy
61
- if collision?
62
- bounce
69
+ if collision_x?
70
+ bounce_x
71
+ move(units)
72
+ end
73
+ if collision_y?
74
+ bounce_y
63
75
  move(units)
64
76
  end
65
77
  end
data/lib/1.8/fox16.so CHANGED
Binary file
data/lib/1.9/fox16.so CHANGED
Binary file
data/lib/fox16/kwargs.rb CHANGED
@@ -236,11 +236,11 @@ module Fox
236
236
  end
237
237
  end
238
238
 
239
- class FXSpring
239
+ class FXDockTitle
240
240
  alias old_initialize initialize
241
- def initialize(p, *args, &blk)
242
- argument_names = %w{opts relw relh x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
243
- default_params = { :opts => 0, :relw => 0, :relh => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
241
+ def initialize(p, text, *args, &blk)
242
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
243
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL|JUSTIFY_CENTER_X|JUSTIFY_CENTER_Y, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
244
244
  params = {}
245
245
  params = args.pop if args.last.is_a? Hash
246
246
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -250,127 +250,135 @@ module Fox
250
250
  end
251
251
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
252
252
  params = default_params.merge(params)
253
- old_initialize(p, params[:opts], params[:relw], params[:relh], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
253
+ old_initialize(p, text, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
254
254
  end
255
255
  end
256
256
 
257
- class FXTGAImage
257
+ class FXRealSpinner
258
258
  alias old_initialize initialize
259
- def initialize(a, *args, &blk)
260
- argument_names = %w{pix opts width height}
261
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
259
+ def initialize(p, cols, *args, &blk)
260
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
261
+ default_params = { :target => nil, :selector => 0, :opts => REALSPIN_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
262
262
  params = {}
263
263
  params = args.pop if args.last.is_a? Hash
264
264
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
265
+ if params.key? :padding
266
+ value = params.delete(:padding)
267
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
268
+ end
265
269
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
266
270
  params = default_params.merge(params)
267
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
271
+ old_initialize(p, cols, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
268
272
  end
269
273
  end
270
274
 
271
- class FXColorItem
275
+ class FXHeaderItem
272
276
  alias old_initialize initialize
273
- def initialize(text, clr, *args, &blk)
274
- argument_names = %w{data}
275
- default_params = { :data => nil }
277
+ def initialize(text, *args, &blk)
278
+ argument_names = %w{ic s ptr}
279
+ default_params = { :ic => nil, :s => 0, :ptr => nil }
276
280
  params = {}
277
281
  params = args.pop if args.last.is_a? Hash
278
282
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
279
283
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
280
284
  params = default_params.merge(params)
281
- old_initialize(text, clr, params[:data], &blk)
285
+ old_initialize(text, params[:ic], params[:s], params[:ptr], &blk)
282
286
  end
283
287
  end
284
288
 
285
- class FXColorList
289
+ class FXHeader
286
290
  alias old_initialize initialize
287
291
  def initialize(p, *args, &blk)
288
- argument_names = %w{target selector opts x y width height}
289
- default_params = { :target => nil, :selector => 0, :opts => LIST_BROWSESELECT, :x => 0, :y => 0, :width => 0, :height => 0 }
292
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
293
+ default_params = { :target => nil, :selector => 0, :opts => HEADER_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
290
294
  params = {}
291
295
  params = args.pop if args.last.is_a? Hash
292
296
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
297
+ if params.key? :padding
298
+ value = params.delete(:padding)
299
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
300
+ end
293
301
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
294
302
  params = default_params.merge(params)
295
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
303
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
296
304
  end
297
305
  end
298
306
 
299
- class FXApp
307
+ class FXScrollBar
300
308
  alias old_initialize initialize
301
- def initialize(*args, &blk)
302
- argument_names = %w{appName vendorName}
303
- default_params = { :appName => "Application", :vendorName => "FoxDefault" }
309
+ def initialize(p, *args, &blk)
310
+ argument_names = %w{target selector opts x y width height}
311
+ default_params = { :target => nil, :selector => 0, :opts => SCROLLBAR_VERTICAL, :x => 0, :y => 0, :width => 0, :height => 0 }
304
312
  params = {}
305
313
  params = args.pop if args.last.is_a? Hash
306
314
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
307
315
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
308
316
  params = default_params.merge(params)
309
- old_initialize(params[:appName], params[:vendorName], &blk)
317
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
310
318
  end
311
319
  end
312
320
 
313
- class FXColorBar
321
+ class FXDirItem
314
322
  alias old_initialize initialize
315
- def initialize(parent, *args, &blk)
316
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
317
- default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
323
+ def initialize(text, *args, &blk)
324
+ argument_names = %w{oi ci data}
325
+ default_params = { :oi => nil, :ci => nil, :data => nil }
318
326
  params = {}
319
327
  params = args.pop if args.last.is_a? Hash
320
328
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
321
- if params.key? :padding
322
- value = params.delete(:padding)
323
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
324
- end
325
329
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
326
330
  params = default_params.merge(params)
327
- old_initialize(parent, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
331
+ old_initialize(text, params[:oi], params[:ci], params[:data], &blk)
328
332
  end
329
333
  end
330
334
 
331
- class FXTreeItem
335
+ class FXDirList
332
336
  alias old_initialize initialize
333
- def initialize(text, *args, &blk)
334
- argument_names = %w{openIcon closedIcon data}
335
- default_params = { :openIcon => nil, :closedIcon => nil, :data => nil }
337
+ def initialize(p, *args, &blk)
338
+ argument_names = %w{target selector opts x y width height}
339
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
336
340
  params = {}
337
341
  params = args.pop if args.last.is_a? Hash
338
342
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
339
343
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
340
344
  params = default_params.merge(params)
341
- old_initialize(text, params[:openIcon], params[:closedIcon], params[:data], &blk)
345
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
342
346
  end
343
347
  end
344
348
 
345
- class FXTreeList
349
+ class FXTextField
346
350
  alias old_initialize initialize
347
- def initialize(p, *args, &blk)
348
- argument_names = %w{target selector opts x y width height}
349
- default_params = { :target => nil, :selector => 0, :opts => TREELIST_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
351
+ def initialize(p, ncols, *args, &blk)
352
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
353
+ default_params = { :target => nil, :selector => 0, :opts => TEXTFIELD_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
350
354
  params = {}
351
355
  params = args.pop if args.last.is_a? Hash
352
356
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
357
+ if params.key? :padding
358
+ value = params.delete(:padding)
359
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
360
+ end
353
361
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
354
362
  params = default_params.merge(params)
355
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
363
+ old_initialize(p, ncols, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
356
364
  end
357
365
  end
358
366
 
359
- class FXInputDialog
367
+ class FXRGBImage
360
368
  alias old_initialize initialize
361
- def initialize(owner, caption, label, *args, &blk)
362
- argument_names = %w{icon opts x y width height}
363
- default_params = { :icon => nil, :opts => INPUTDIALOG_STRING, :x => 0, :y => 0, :width => 0, :height => 0 }
369
+ def initialize(a, *args, &blk)
370
+ argument_names = %w{pix opts width height}
371
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
364
372
  params = {}
365
373
  params = args.pop if args.last.is_a? Hash
366
374
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
367
375
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
368
376
  params = default_params.merge(params)
369
- old_initialize(owner, caption, label, params[:icon], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
377
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
370
378
  end
371
379
  end
372
380
 
373
- class FXReplaceDialog
381
+ class FXSearchDialog
374
382
  alias old_initialize initialize
375
383
  def initialize(owner, caption, *args, &blk)
376
384
  argument_names = %w{ic opts x y width height}
@@ -384,67 +392,71 @@ module Fox
384
392
  end
385
393
  end
386
394
 
387
- class FXScrollPane
395
+ class FXMenuCaption
388
396
  alias old_initialize initialize
389
- def initialize(owner, nvis, *args, &blk)
390
- argument_names = %w{opts}
391
- default_params = { :opts => 0 }
397
+ def initialize(parent, text, *args, &blk)
398
+ argument_names = %w{icon opts}
399
+ default_params = { :icon => nil, :opts => 0 }
392
400
  params = {}
393
401
  params = args.pop if args.last.is_a? Hash
394
402
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
395
403
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
396
404
  params = default_params.merge(params)
397
- old_initialize(owner, nvis, params[:opts], &blk)
405
+ old_initialize(parent, text, params[:icon], params[:opts], &blk)
398
406
  end
399
407
  end
400
408
 
401
- class FXMenuTitle
409
+ class FXProgressDialog
402
410
  alias old_initialize initialize
403
- def initialize(parent, text, *args, &blk)
404
- argument_names = %w{icon popupMenu opts}
405
- default_params = { :icon => nil, :popupMenu => nil, :opts => 0 }
411
+ def initialize(owner, caption, label, *args, &blk)
412
+ argument_names = %w{opts x y width height}
413
+ default_params = { :opts => PROGRESSDIALOG_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
406
414
  params = {}
407
415
  params = args.pop if args.last.is_a? Hash
408
416
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
409
417
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
410
418
  params = default_params.merge(params)
411
- old_initialize(parent, text, params[:icon], params[:popupMenu], params[:opts], &blk)
419
+ old_initialize(owner, caption, label, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
412
420
  end
413
421
  end
414
422
 
415
- class FXFileStream
423
+ class FXSwitcher
416
424
  alias old_initialize initialize
417
- def initialize(*args, &blk)
418
- argument_names = %w{cont}
419
- default_params = { :cont => nil }
425
+ def initialize(p, *args, &blk)
426
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
427
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING }
420
428
  params = {}
421
429
  params = args.pop if args.last.is_a? Hash
422
430
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
431
+ if params.key? :padding
432
+ value = params.delete(:padding)
433
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
434
+ end
423
435
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
424
436
  params = default_params.merge(params)
425
- old_initialize(params[:cont], &blk)
437
+ old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
426
438
  end
427
439
  end
428
440
 
429
- class FXStream
441
+ class FXReplaceDialog
430
442
  alias old_initialize initialize
431
- def initialize(*args, &blk)
432
- argument_names = %w{cont}
433
- default_params = { :cont => nil }
443
+ def initialize(owner, caption, *args, &blk)
444
+ argument_names = %w{ic opts x y width height}
445
+ default_params = { :ic => nil, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
434
446
  params = {}
435
447
  params = args.pop if args.last.is_a? Hash
436
448
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
437
449
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
438
450
  params = default_params.merge(params)
439
- old_initialize(params[:cont], &blk)
451
+ old_initialize(owner, caption, params[:ic], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
440
452
  end
441
453
  end
442
454
 
443
- class FXFontDialog
455
+ class FXDirDialog
444
456
  alias old_initialize initialize
445
457
  def initialize(owner, name, *args, &blk)
446
458
  argument_names = %w{opts x y width height}
447
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 600, :height => 380 }
459
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 500, :height => 300 }
448
460
  params = {}
449
461
  params = args.pop if args.last.is_a? Hash
450
462
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -454,25 +466,25 @@ module Fox
454
466
  end
455
467
  end
456
468
 
457
- class FXBMPImage
469
+ class FXFileSelector
458
470
  alias old_initialize initialize
459
- def initialize(a, *args, &blk)
460
- argument_names = %w{pix opts width height}
461
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
471
+ def initialize(p, *args, &blk)
472
+ argument_names = %w{target selector opts x y width height}
473
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
462
474
  params = {}
463
475
  params = args.pop if args.last.is_a? Hash
464
476
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
465
477
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
466
478
  params = default_params.merge(params)
467
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
479
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
468
480
  end
469
481
  end
470
482
 
471
- class FXTabBook
483
+ class FXMenuButton
472
484
  alias old_initialize initialize
473
- def initialize(p, *args, &blk)
474
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
475
- default_params = { :target => nil, :selector => 0, :opts => TABBOOK_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING }
485
+ def initialize(parent, text, *args, &blk)
486
+ argument_names = %w{icon popupMenu opts x y width height padLeft padRight padTop padBottom}
487
+ default_params = { :icon => nil, :popupMenu => nil, :opts => JUSTIFY_NORMAL|ICON_BEFORE_TEXT|MENUBUTTON_DOWN, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING }
476
488
  params = {}
477
489
  params = args.pop if args.last.is_a? Hash
478
490
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -482,89 +494,85 @@ module Fox
482
494
  end
483
495
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
484
496
  params = default_params.merge(params)
485
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
497
+ old_initialize(parent, text, params[:icon], params[:popupMenu], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
486
498
  end
487
499
  end
488
500
 
489
- class FXSpinner
501
+ class FXTIFIcon
490
502
  alias old_initialize initialize
491
- def initialize(p, cols, *args, &blk)
492
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
493
- default_params = { :target => nil, :selector => 0, :opts => SPIN_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
503
+ def initialize(a, *args, &blk)
504
+ argument_names = %w{pix clr opts width height}
505
+ default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
494
506
  params = {}
495
507
  params = args.pop if args.last.is_a? Hash
496
508
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
497
- if params.key? :padding
498
- value = params.delete(:padding)
499
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
500
- end
501
509
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
502
510
  params = default_params.merge(params)
503
- old_initialize(p, cols, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
511
+ old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
504
512
  end
505
513
  end
506
514
 
507
- class FXMDIClient
515
+ class FXColorRing
508
516
  alias old_initialize initialize
509
517
  def initialize(p, *args, &blk)
510
- argument_names = %w{opts x y width height}
511
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
518
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
519
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
512
520
  params = {}
513
521
  params = args.pop if args.last.is_a? Hash
514
522
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
523
+ if params.key? :padding
524
+ value = params.delete(:padding)
525
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
526
+ end
515
527
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
516
528
  params = default_params.merge(params)
517
- old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
529
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
518
530
  end
519
531
  end
520
532
 
521
- class FXColorSelector
533
+ class FXBMPImage
522
534
  alias old_initialize initialize
523
- def initialize(parent, *args, &blk)
524
- argument_names = %w{target selector opts x y width height}
525
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
535
+ def initialize(a, *args, &blk)
536
+ argument_names = %w{pix opts width height}
537
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
526
538
  params = {}
527
539
  params = args.pop if args.last.is_a? Hash
528
540
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
529
541
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
530
542
  params = default_params.merge(params)
531
- old_initialize(parent, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
543
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
532
544
  end
533
545
  end
534
546
 
535
- class FXToolBarTab
547
+ class FXIcon
536
548
  alias old_initialize initialize
537
- def initialize(p, *args, &blk)
538
- argument_names = %w{target selector opts x y width height}
539
- default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
549
+ def initialize(app, *args, &blk)
550
+ argument_names = %w{pix clr opts width height}
551
+ default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
540
552
  params = {}
541
553
  params = args.pop if args.last.is_a? Hash
542
554
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
543
555
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
544
556
  params = default_params.merge(params)
545
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
557
+ old_initialize(app, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
546
558
  end
547
559
  end
548
560
 
549
- class FXDockTitle
561
+ class FXTGAIcon
550
562
  alias old_initialize initialize
551
- def initialize(p, text, *args, &blk)
552
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
553
- default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL|JUSTIFY_CENTER_X|JUSTIFY_CENTER_Y, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
563
+ def initialize(a, *args, &blk)
564
+ argument_names = %w{pix clr opts width height}
565
+ default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
554
566
  params = {}
555
567
  params = args.pop if args.last.is_a? Hash
556
568
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
557
- if params.key? :padding
558
- value = params.delete(:padding)
559
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
560
- end
561
569
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
562
570
  params = default_params.merge(params)
563
- old_initialize(p, text, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
571
+ old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
564
572
  end
565
573
  end
566
574
 
567
- class FXRGBIcon
575
+ class FXGIFIcon
568
576
  alias old_initialize initialize
569
577
  def initialize(a, *args, &blk)
570
578
  argument_names = %w{pix clr opts width height}
@@ -578,11 +586,25 @@ module Fox
578
586
  end
579
587
  end
580
588
 
581
- class FXCheckButton
589
+ class FXFontDialog
582
590
  alias old_initialize initialize
583
- def initialize(parent, text, *args, &blk)
591
+ def initialize(owner, name, *args, &blk)
592
+ argument_names = %w{opts x y width height}
593
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 600, :height => 380 }
594
+ params = {}
595
+ params = args.pop if args.last.is_a? Hash
596
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
597
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
598
+ params = default_params.merge(params)
599
+ old_initialize(owner, name, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
600
+ end
601
+ end
602
+
603
+ class FXColorBar
604
+ alias old_initialize initialize
605
+ def initialize(parent, *args, &blk)
584
606
  argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
585
- default_params = { :target => nil, :selector => 0, :opts => CHECKBUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
607
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
586
608
  params = {}
587
609
  params = args.pop if args.last.is_a? Hash
588
610
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -592,33 +614,43 @@ module Fox
592
614
  end
593
615
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
594
616
  params = default_params.merge(params)
595
- old_initialize(parent, text, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
617
+ old_initialize(parent, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
596
618
  end
597
619
  end
598
620
 
599
- class FXBitmapFrame
621
+ class FXMenuCommand
600
622
  alias old_initialize initialize
601
- def initialize(p, bmp, *args, &blk)
602
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
603
- default_params = { :opts => FRAME_SUNKEN|FRAME_THICK, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
623
+ def initialize(p, text, *args, &blk)
624
+ argument_names = %w{ic target selector opts}
625
+ default_params = { :ic => nil, :target => nil, :selector => 0, :opts => 0 }
604
626
  params = {}
605
627
  params = args.pop if args.last.is_a? Hash
606
628
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
607
- if params.key? :padding
608
- value = params.delete(:padding)
609
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
610
- end
611
629
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
612
630
  params = default_params.merge(params)
613
- old_initialize(p, bmp, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
631
+ old_initialize(p, text, params[:ic], params[:target], params[:selector], params[:opts], &blk)
614
632
  end
615
633
  end
616
634
 
617
- class FXArrowButton
635
+ class FXFileDialog
636
+ alias old_initialize initialize
637
+ def initialize(owner, name, *args, &blk)
638
+ argument_names = %w{opts x y width height}
639
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 500, :height => 300 }
640
+ params = {}
641
+ params = args.pop if args.last.is_a? Hash
642
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
643
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
644
+ params = default_params.merge(params)
645
+ old_initialize(owner, name, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
646
+ end
647
+ end
648
+
649
+ class FXColorWell
618
650
  alias old_initialize initialize
619
651
  def initialize(parent, *args, &blk)
620
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
621
- default_params = { :target => nil, :selector => 0, :opts => ARROW_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
652
+ argument_names = %w{color target selector opts x y width height padLeft padRight padTop padBottom}
653
+ default_params = { :color => 0, :target => nil, :selector => 0, :opts => COLORWELL_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
622
654
  params = {}
623
655
  params = args.pop if args.last.is_a? Hash
624
656
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -628,89 +660,85 @@ module Fox
628
660
  end
629
661
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
630
662
  params = default_params.merge(params)
631
- old_initialize(parent, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
663
+ old_initialize(parent, params[:color], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
632
664
  end
633
665
  end
634
666
 
635
- class FXXBMImage
667
+ class FXGIFCursor
636
668
  alias old_initialize initialize
637
- def initialize(a, *args, &blk)
638
- argument_names = %w{pixels mask opts width height}
639
- default_params = { :pixels => nil, :mask => nil, :opts => 0, :width => 1, :height => 1 }
669
+ def initialize(a, pix, *args, &blk)
670
+ argument_names = %w{hx hy}
671
+ default_params = { :hx => -1, :hy => -1 }
640
672
  params = {}
641
673
  params = args.pop if args.last.is_a? Hash
642
674
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
643
675
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
644
676
  params = default_params.merge(params)
645
- old_initialize(a, params[:pixels], params[:mask], params[:opts], params[:width], params[:height], &blk)
677
+ old_initialize(a, pix, params[:hx], params[:hy], &blk)
646
678
  end
647
679
  end
648
680
 
649
- class FXComboBox
681
+ class FXBitmap
650
682
  alias old_initialize initialize
651
- def initialize(p, cols, *args, &blk)
652
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
653
- default_params = { :target => nil, :selector => 0, :opts => COMBOBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
683
+ def initialize(app, *args, &blk)
684
+ argument_names = %w{pixels opts width height}
685
+ default_params = { :pixels => nil, :opts => 0, :width => 1, :height => 1 }
654
686
  params = {}
655
687
  params = args.pop if args.last.is_a? Hash
656
688
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
657
- if params.key? :padding
658
- value = params.delete(:padding)
659
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
660
- end
661
689
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
662
690
  params = default_params.merge(params)
663
- old_initialize(p, cols, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
691
+ old_initialize(app, params[:pixels], params[:opts], params[:width], params[:height], &blk)
664
692
  end
665
693
  end
666
694
 
667
- class FXFileItem
695
+ class FXMenuCascade
668
696
  alias old_initialize initialize
669
- def initialize(text, *args, &blk)
670
- argument_names = %w{bi mi ptr}
671
- default_params = { :bi => nil, :mi => nil, :ptr => nil }
697
+ def initialize(parent, text, *args, &blk)
698
+ argument_names = %w{icon popupMenu opts}
699
+ default_params = { :icon => nil, :popupMenu => nil, :opts => 0 }
672
700
  params = {}
673
701
  params = args.pop if args.last.is_a? Hash
674
702
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
675
703
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
676
704
  params = default_params.merge(params)
677
- old_initialize(text, params[:bi], params[:mi], params[:ptr], &blk)
705
+ old_initialize(parent, text, params[:icon], params[:popupMenu], params[:opts], &blk)
678
706
  end
679
707
  end
680
708
 
681
- class FXFileList
709
+ class FXTreeItem
682
710
  alias old_initialize initialize
683
- def initialize(p, *args, &blk)
684
- argument_names = %w{target selector opts x y width height}
685
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
711
+ def initialize(text, *args, &blk)
712
+ argument_names = %w{openIcon closedIcon data}
713
+ default_params = { :openIcon => nil, :closedIcon => nil, :data => nil }
686
714
  params = {}
687
715
  params = args.pop if args.last.is_a? Hash
688
716
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
689
717
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
690
718
  params = default_params.merge(params)
691
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
719
+ old_initialize(text, params[:openIcon], params[:closedIcon], params[:data], &blk)
692
720
  end
693
721
  end
694
722
 
695
- class FXPPMIcon
723
+ class FXTreeList
696
724
  alias old_initialize initialize
697
- def initialize(a, *args, &blk)
698
- argument_names = %w{pix clr opts width height}
699
- default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
725
+ def initialize(p, *args, &blk)
726
+ argument_names = %w{target selector opts x y width height}
727
+ default_params = { :target => nil, :selector => 0, :opts => TREELIST_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
700
728
  params = {}
701
729
  params = args.pop if args.last.is_a? Hash
702
730
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
703
731
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
704
732
  params = default_params.merge(params)
705
- old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
733
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
706
734
  end
707
735
  end
708
736
 
709
- class FXSwitcher
737
+ class FXImageFrame
710
738
  alias old_initialize initialize
711
- def initialize(p, *args, &blk)
739
+ def initialize(p, img, *args, &blk)
712
740
  argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
713
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING }
741
+ default_params = { :opts => FRAME_SUNKEN|FRAME_THICK, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
714
742
  params = {}
715
743
  params = args.pop if args.last.is_a? Hash
716
744
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -720,15 +748,57 @@ module Fox
720
748
  end
721
749
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
722
750
  params = default_params.merge(params)
723
- old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
751
+ old_initialize(p, img, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
724
752
  end
725
753
  end
726
754
 
727
- class FXText
755
+ class FXToolTip
756
+ alias old_initialize initialize
757
+ def initialize(app, *args, &blk)
758
+ argument_names = %w{opts x y width height}
759
+ default_params = { :opts => TOOLTIP_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
760
+ params = {}
761
+ params = args.pop if args.last.is_a? Hash
762
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
763
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
764
+ params = default_params.merge(params)
765
+ old_initialize(app, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
766
+ end
767
+ end
768
+
769
+ class FXFoldingItem
770
+ alias old_initialize initialize
771
+ def initialize(text, *args, &blk)
772
+ argument_names = %w{openIcon closedIcon data}
773
+ default_params = { :openIcon => nil, :closedIcon => nil, :data => nil }
774
+ params = {}
775
+ params = args.pop if args.last.is_a? Hash
776
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
777
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
778
+ params = default_params.merge(params)
779
+ old_initialize(text, params[:openIcon], params[:closedIcon], params[:data], &blk)
780
+ end
781
+ end
782
+
783
+ class FXFoldingList
728
784
  alias old_initialize initialize
729
785
  def initialize(p, *args, &blk)
730
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
731
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 3, :padRight => 3, :padTop => 2, :padBottom => 2 }
786
+ argument_names = %w{target selector opts x y width height}
787
+ default_params = { :target => nil, :selector => 0, :opts => TREELIST_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
788
+ params = {}
789
+ params = args.pop if args.last.is_a? Hash
790
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
791
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
792
+ params = default_params.merge(params)
793
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
794
+ end
795
+ end
796
+
797
+ class FXPicker
798
+ alias old_initialize initialize
799
+ def initialize(p, text, *args, &blk)
800
+ argument_names = %w{ic target selector opts x y width height padLeft padRight padTop padBottom}
801
+ default_params = { :ic => nil, :target => nil, :selector => 0, :opts => BUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
732
802
  params = {}
733
803
  params = args.pop if args.last.is_a? Hash
734
804
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -738,32 +808,49 @@ module Fox
738
808
  end
739
809
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
740
810
  params = default_params.merge(params)
741
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
811
+ old_initialize(p, text, params[:ic], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
742
812
  end
743
- alias old_findText findText
744
- def findText(string, *args)
745
- argument_names = %w{start flags}
746
- default_params = { :start => 0, :flags => SEARCH_FORWARD|SEARCH_WRAP|SEARCH_EXACT }
813
+ end
814
+
815
+ class FXChoiceBox
816
+ alias old_initialize initialize
817
+ def initialize(owner, caption, text, icon, choices, *args, &blk)
818
+ argument_names = %w{opts x y width height}
819
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
747
820
  params = {}
748
821
  params = args.pop if args.last.is_a? Hash
749
822
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
750
823
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
751
824
  params = default_params.merge(params)
752
- old_findText(string, params[:start], params[:flags])
825
+ old_initialize(owner, caption, text, icon, choices, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
753
826
  end
754
827
  end
755
828
 
756
- class FXGIFImage
829
+ class FXBitmapView
757
830
  alias old_initialize initialize
758
- def initialize(a, *args, &blk)
759
- argument_names = %w{pix opts width height}
760
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
831
+ def initialize(p, *args, &blk)
832
+ argument_names = %w{bmp target selector opts x y width height}
833
+ default_params = { :bmp => nil, :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
761
834
  params = {}
762
835
  params = args.pop if args.last.is_a? Hash
763
836
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
764
837
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
765
838
  params = default_params.merge(params)
766
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
839
+ old_initialize(p, params[:bmp], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
840
+ end
841
+ end
842
+
843
+ class FXScrollPane
844
+ alias old_initialize initialize
845
+ def initialize(owner, nvis, *args, &blk)
846
+ argument_names = %w{opts}
847
+ default_params = { :opts => 0 }
848
+ params = {}
849
+ params = args.pop if args.last.is_a? Hash
850
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
851
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
852
+ params = default_params.merge(params)
853
+ old_initialize(owner, nvis, params[:opts], &blk)
767
854
  end
768
855
  end
769
856
 
@@ -821,57 +908,61 @@ module Fox
821
908
  end
822
909
  end
823
910
 
824
- class FXRuler
911
+ class FXComposite
825
912
  alias old_initialize initialize
826
- def initialize(p, *args, &blk)
827
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
828
- default_params = { :target => nil, :selector => 0, :opts => RULER_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
913
+ def initialize(parent, *args, &blk)
914
+ argument_names = %w{opts x y width height}
915
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
829
916
  params = {}
830
917
  params = args.pop if args.last.is_a? Hash
831
918
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
832
- if params.key? :padding
833
- value = params.delete(:padding)
834
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
835
- end
836
919
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
837
920
  params = default_params.merge(params)
838
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
921
+ old_initialize(parent, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
839
922
  end
840
923
  end
841
924
 
842
- class FXFoldingItem
925
+ class FXProgressBar
843
926
  alias old_initialize initialize
844
- def initialize(text, *args, &blk)
845
- argument_names = %w{openIcon closedIcon data}
846
- default_params = { :openIcon => nil, :closedIcon => nil, :data => nil }
927
+ def initialize(p, *args, &blk)
928
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
929
+ default_params = { :target => nil, :selector => 0, :opts => PROGRESSBAR_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
847
930
  params = {}
848
931
  params = args.pop if args.last.is_a? Hash
849
932
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
933
+ if params.key? :padding
934
+ value = params.delete(:padding)
935
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
936
+ end
850
937
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
851
938
  params = default_params.merge(params)
852
- old_initialize(text, params[:openIcon], params[:closedIcon], params[:data], &blk)
939
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
853
940
  end
854
941
  end
855
942
 
856
- class FXFoldingList
943
+ class FXBitmapFrame
857
944
  alias old_initialize initialize
858
- def initialize(p, *args, &blk)
859
- argument_names = %w{target selector opts x y width height}
860
- default_params = { :target => nil, :selector => 0, :opts => TREELIST_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
945
+ def initialize(p, bmp, *args, &blk)
946
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
947
+ default_params = { :opts => FRAME_SUNKEN|FRAME_THICK, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
861
948
  params = {}
862
949
  params = args.pop if args.last.is_a? Hash
863
950
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
951
+ if params.key? :padding
952
+ value = params.delete(:padding)
953
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
954
+ end
864
955
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
865
956
  params = default_params.merge(params)
866
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
957
+ old_initialize(p, bmp, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
867
958
  end
868
959
  end
869
960
 
870
- class FXDialogBox
961
+ class FXSlider
871
962
  alias old_initialize initialize
872
- def initialize(owner, title, *args, &blk)
873
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
874
- default_params = { :opts => DECOR_TITLE|DECOR_BORDER, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 10, :padRight => 10, :padTop => 10, :padBottom => 10, :hSpacing => 4, :vSpacing => 4 }
963
+ def initialize(p, *args, &blk)
964
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
965
+ default_params = { :target => nil, :selector => 0, :opts => SLIDER_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
875
966
  params = {}
876
967
  params = args.pop if args.last.is_a? Hash
877
968
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -881,27 +972,27 @@ module Fox
881
972
  end
882
973
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
883
974
  params = default_params.merge(params)
884
- old_initialize(owner, title, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
975
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
885
976
  end
886
977
  end
887
978
 
888
- class FXRulerView
979
+ class FXMDIChild
889
980
  alias old_initialize initialize
890
- def initialize(p, *args, &blk)
891
- argument_names = %w{target selector opts x y width height}
892
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
981
+ def initialize(p, name, *args, &blk)
982
+ argument_names = %w{ic pup opts x y width height}
983
+ default_params = { :ic => nil, :pup => nil, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
893
984
  params = {}
894
985
  params = args.pop if args.last.is_a? Hash
895
986
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
896
987
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
897
988
  params = default_params.merge(params)
898
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
989
+ old_initialize(p, name, params[:ic], params[:pup], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
899
990
  end
900
991
  end
901
992
 
902
- class FXScrollWindow
993
+ class FXPrintDialog
903
994
  alias old_initialize initialize
904
- def initialize(p, *args, &blk)
995
+ def initialize(owner, name, *args, &blk)
905
996
  argument_names = %w{opts x y width height}
906
997
  default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
907
998
  params = {}
@@ -909,33 +1000,15 @@ module Fox
909
1000
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
910
1001
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
911
1002
  params = default_params.merge(params)
912
- old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1003
+ old_initialize(owner, name, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
913
1004
  end
914
1005
  end
915
1006
 
916
- class FXMainWindow
917
- alias old_initialize initialize
918
- def initialize(app, title, *args, &blk)
919
- argument_names = %w{icon miniIcon opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
920
- default_params = { :icon => nil, :miniIcon => nil, :opts => DECOR_ALL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0, :hSpacing => 4, :vSpacing => 4 }
921
- params = {}
922
- params = args.pop if args.last.is_a? Hash
923
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
924
- if params.key? :padding
925
- value = params.delete(:padding)
926
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
927
- end
928
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
929
- params = default_params.merge(params)
930
- old_initialize(app, title, params[:icon], params[:miniIcon], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
931
- end
932
- end
933
-
934
- class FXHorizontalFrame
1007
+ class FXSpring
935
1008
  alias old_initialize initialize
936
1009
  def initialize(p, *args, &blk)
937
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
938
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1010
+ argument_names = %w{opts relw relh x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1011
+ default_params = { :opts => 0, :relw => 0, :relh => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
939
1012
  params = {}
940
1013
  params = args.pop if args.last.is_a? Hash
941
1014
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -945,43 +1018,47 @@ module Fox
945
1018
  end
946
1019
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
947
1020
  params = default_params.merge(params)
948
- old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1021
+ old_initialize(p, params[:opts], params[:relw], params[:relh], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
949
1022
  end
950
1023
  end
951
1024
 
952
- class FXScrollBar
1025
+ class FXPopup
953
1026
  alias old_initialize initialize
954
- def initialize(p, *args, &blk)
955
- argument_names = %w{target selector opts x y width height}
956
- default_params = { :target => nil, :selector => 0, :opts => SCROLLBAR_VERTICAL, :x => 0, :y => 0, :width => 0, :height => 0 }
1027
+ def initialize(owner, *args, &blk)
1028
+ argument_names = %w{opts x y width height}
1029
+ default_params = { :opts => POPUP_VERTICAL|FRAME_RAISED|FRAME_THICK, :x => 0, :y => 0, :width => 0, :height => 0 }
957
1030
  params = {}
958
1031
  params = args.pop if args.last.is_a? Hash
959
1032
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
960
1033
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
961
1034
  params = default_params.merge(params)
962
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1035
+ old_initialize(owner, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
963
1036
  end
964
1037
  end
965
1038
 
966
- class FXBitmapView
1039
+ class FXPacker
967
1040
  alias old_initialize initialize
968
- def initialize(p, *args, &blk)
969
- argument_names = %w{bmp target selector opts x y width height}
970
- default_params = { :bmp => nil, :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1041
+ def initialize(parent, *args, &blk)
1042
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1043
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
971
1044
  params = {}
972
1045
  params = args.pop if args.last.is_a? Hash
973
1046
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1047
+ if params.key? :padding
1048
+ value = params.delete(:padding)
1049
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1050
+ end
974
1051
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
975
1052
  params = default_params.merge(params)
976
- old_initialize(p, params[:bmp], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1053
+ old_initialize(parent, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
977
1054
  end
978
1055
  end
979
1056
 
980
- class FXColorRing
1057
+ class FXGroupBox
981
1058
  alias old_initialize initialize
982
- def initialize(p, *args, &blk)
983
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
984
- default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1059
+ def initialize(parent, text, *args, &blk)
1060
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1061
+ default_params = { :opts => GROUPBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
985
1062
  params = {}
986
1063
  params = args.pop if args.last.is_a? Hash
987
1064
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -991,47 +1068,43 @@ module Fox
991
1068
  end
992
1069
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
993
1070
  params = default_params.merge(params)
994
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1071
+ old_initialize(parent, text, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
995
1072
  end
996
1073
  end
997
1074
 
998
- class FXButton
1075
+ class FXStream
999
1076
  alias old_initialize initialize
1000
- def initialize(parent, text, *args, &blk)
1001
- argument_names = %w{icon target selector opts x y width height padLeft padRight padTop padBottom}
1002
- default_params = { :icon => nil, :target => nil, :selector => 0, :opts => BUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1077
+ def initialize(*args, &blk)
1078
+ argument_names = %w{cont}
1079
+ default_params = { :cont => nil }
1003
1080
  params = {}
1004
1081
  params = args.pop if args.last.is_a? Hash
1005
1082
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1006
- if params.key? :padding
1007
- value = params.delete(:padding)
1008
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1009
- end
1010
1083
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1011
1084
  params = default_params.merge(params)
1012
- old_initialize(parent, text, params[:icon], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1085
+ old_initialize(params[:cont], &blk)
1013
1086
  end
1014
1087
  end
1015
1088
 
1016
- class FXIconItem
1089
+ class FXMDIDeleteButton
1017
1090
  alias old_initialize initialize
1018
- def initialize(text, *args, &blk)
1019
- argument_names = %w{bigIcon miniIcon data}
1020
- default_params = { :bigIcon => nil, :miniIcon => nil, :data => nil }
1091
+ def initialize(p, *args, &blk)
1092
+ argument_names = %w{target selector opts x y width height}
1093
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1021
1094
  params = {}
1022
1095
  params = args.pop if args.last.is_a? Hash
1023
1096
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1024
1097
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1025
1098
  params = default_params.merge(params)
1026
- old_initialize(text, params[:bigIcon], params[:miniIcon], params[:data], &blk)
1099
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1027
1100
  end
1028
1101
  end
1029
1102
 
1030
- class FXIconList
1103
+ class FXMDIRestoreButton
1031
1104
  alias old_initialize initialize
1032
1105
  def initialize(p, *args, &blk)
1033
1106
  argument_names = %w{target selector opts x y width height}
1034
- default_params = { :target => nil, :selector => 0, :opts => ICONLIST_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
1107
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1035
1108
  params = {}
1036
1109
  params = args.pop if args.last.is_a? Hash
1037
1110
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1041,109 +1114,105 @@ module Fox
1041
1114
  end
1042
1115
  end
1043
1116
 
1044
- class FXVerticalFrame
1117
+ class FXMDIMaximizeButton
1045
1118
  alias old_initialize initialize
1046
1119
  def initialize(p, *args, &blk)
1047
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1048
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1120
+ argument_names = %w{target selector opts x y width height}
1121
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1049
1122
  params = {}
1050
1123
  params = args.pop if args.last.is_a? Hash
1051
1124
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1052
- if params.key? :padding
1053
- value = params.delete(:padding)
1054
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1055
- end
1056
1125
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1057
1126
  params = default_params.merge(params)
1058
- old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1127
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1059
1128
  end
1060
1129
  end
1061
1130
 
1062
- class FXProgressDialog
1131
+ class FXMDIMinimizeButton
1063
1132
  alias old_initialize initialize
1064
- def initialize(owner, caption, label, *args, &blk)
1065
- argument_names = %w{opts x y width height}
1066
- default_params = { :opts => PROGRESSDIALOG_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
1133
+ def initialize(p, *args, &blk)
1134
+ argument_names = %w{target selector opts x y width height}
1135
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1067
1136
  params = {}
1068
1137
  params = args.pop if args.last.is_a? Hash
1069
1138
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1070
1139
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1071
1140
  params = default_params.merge(params)
1072
- old_initialize(owner, caption, label, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1141
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1073
1142
  end
1074
1143
  end
1075
1144
 
1076
- class FXToolBarShell
1145
+ class FXMDIWindowButton
1077
1146
  alias old_initialize initialize
1078
- def initialize(owner, *args, &blk)
1079
- argument_names = %w{opts x y width height hSpacing vSpacing}
1080
- default_params = { :opts => FRAME_RAISED|FRAME_THICK, :x => 0, :y => 0, :width => 0, :height => 0, :hSpacing => 4, :vSpacing => 4 }
1147
+ def initialize(p, pup, *args, &blk)
1148
+ argument_names = %w{target selector opts x y width height}
1149
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1081
1150
  params = {}
1082
1151
  params = args.pop if args.last.is_a? Hash
1083
1152
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1084
1153
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1085
1154
  params = default_params.merge(params)
1086
- old_initialize(owner, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:hSpacing], params[:vSpacing], &blk)
1155
+ old_initialize(p, pup, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1087
1156
  end
1088
1157
  end
1089
1158
 
1090
- class FXListItem
1159
+ class FXMDIMenu
1091
1160
  alias old_initialize initialize
1092
- def initialize(text, *args, &blk)
1093
- argument_names = %w{icon data}
1094
- default_params = { :icon => nil, :data => nil }
1161
+ def initialize(owner, *args, &blk)
1162
+ argument_names = %w{target}
1163
+ default_params = { :target => nil }
1095
1164
  params = {}
1096
1165
  params = args.pop if args.last.is_a? Hash
1097
1166
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1098
1167
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1099
1168
  params = default_params.merge(params)
1100
- old_initialize(text, params[:icon], params[:data], &blk)
1169
+ old_initialize(owner, params[:target], &blk)
1101
1170
  end
1102
1171
  end
1103
1172
 
1104
- class FXList
1173
+ class FXIconItem
1105
1174
  alias old_initialize initialize
1106
- def initialize(p, *args, &blk)
1107
- argument_names = %w{target selector opts x y width height}
1108
- default_params = { :target => nil, :selector => 0, :opts => LIST_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
1175
+ def initialize(text, *args, &blk)
1176
+ argument_names = %w{bigIcon miniIcon data}
1177
+ default_params = { :bigIcon => nil, :miniIcon => nil, :data => nil }
1109
1178
  params = {}
1110
1179
  params = args.pop if args.last.is_a? Hash
1111
1180
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1112
1181
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1113
1182
  params = default_params.merge(params)
1114
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1183
+ old_initialize(text, params[:bigIcon], params[:miniIcon], params[:data], &blk)
1115
1184
  end
1116
1185
  end
1117
1186
 
1118
- class FXXPMImage
1187
+ class FXIconList
1119
1188
  alias old_initialize initialize
1120
- def initialize(a, *args, &blk)
1121
- argument_names = %w{pix opts width height}
1122
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
1189
+ def initialize(p, *args, &blk)
1190
+ argument_names = %w{target selector opts x y width height}
1191
+ default_params = { :target => nil, :selector => 0, :opts => ICONLIST_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
1123
1192
  params = {}
1124
1193
  params = args.pop if args.last.is_a? Hash
1125
1194
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1126
1195
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1127
1196
  params = default_params.merge(params)
1128
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
1197
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1129
1198
  end
1130
1199
  end
1131
1200
 
1132
- class FXRGBImage
1201
+ class FXImageView
1133
1202
  alias old_initialize initialize
1134
- def initialize(a, *args, &blk)
1135
- argument_names = %w{pix opts width height}
1136
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
1203
+ def initialize(p, *args, &blk)
1204
+ argument_names = %w{img target selector opts x y width height}
1205
+ default_params = { :img => nil, :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1137
1206
  params = {}
1138
1207
  params = args.pop if args.last.is_a? Hash
1139
1208
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1140
1209
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1141
1210
  params = default_params.merge(params)
1142
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
1211
+ old_initialize(p, params[:img], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1143
1212
  end
1144
1213
  end
1145
1214
 
1146
- class FXXPMIcon
1215
+ class FXPCXIcon
1147
1216
  alias old_initialize initialize
1148
1217
  def initialize(a, *args, &blk)
1149
1218
  argument_names = %w{pix clr opts width height}
@@ -1157,11 +1226,11 @@ module Fox
1157
1226
  end
1158
1227
  end
1159
1228
 
1160
- class FXColorWell
1229
+ class FXShutterItem
1161
1230
  alias old_initialize initialize
1162
- def initialize(parent, *args, &blk)
1163
- argument_names = %w{color target selector opts x y width height padLeft padRight padTop padBottom}
1164
- default_params = { :color => 0, :target => nil, :selector => 0, :opts => COLORWELL_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1231
+ def initialize(p, *args, &blk)
1232
+ argument_names = %w{text icon opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1233
+ default_params = { :text => "", :icon => nil, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1165
1234
  params = {}
1166
1235
  params = args.pop if args.last.is_a? Hash
1167
1236
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1171,15 +1240,15 @@ module Fox
1171
1240
  end
1172
1241
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1173
1242
  params = default_params.merge(params)
1174
- old_initialize(parent, params[:color], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1243
+ old_initialize(p, params[:text], params[:icon], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1175
1244
  end
1176
1245
  end
1177
1246
 
1178
- class FXDockSite
1247
+ class FXShutter
1179
1248
  alias old_initialize initialize
1180
1249
  def initialize(p, *args, &blk)
1181
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1182
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0, :hSpacing => 0, :vSpacing => 0 }
1250
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1251
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1183
1252
  params = {}
1184
1253
  params = args.pop if args.last.is_a? Hash
1185
1254
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1189,29 +1258,25 @@ module Fox
1189
1258
  end
1190
1259
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1191
1260
  params = default_params.merge(params)
1192
- old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1261
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1193
1262
  end
1194
1263
  end
1195
1264
 
1196
- class FXLabel
1265
+ class FXToolBarShell
1197
1266
  alias old_initialize initialize
1198
- def initialize(parent, text, *args, &blk)
1199
- argument_names = %w{icon opts x y width height padLeft padRight padTop padBottom}
1200
- default_params = { :icon => nil, :opts => LABEL_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1267
+ def initialize(owner, *args, &blk)
1268
+ argument_names = %w{opts x y width height hSpacing vSpacing}
1269
+ default_params = { :opts => FRAME_RAISED|FRAME_THICK, :x => 0, :y => 0, :width => 0, :height => 0, :hSpacing => 4, :vSpacing => 4 }
1201
1270
  params = {}
1202
1271
  params = args.pop if args.last.is_a? Hash
1203
1272
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1204
- if params.key? :padding
1205
- value = params.delete(:padding)
1206
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1207
- end
1208
1273
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1209
1274
  params = default_params.merge(params)
1210
- old_initialize(parent, text, params[:icon], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1275
+ old_initialize(owner, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:hSpacing], params[:vSpacing], &blk)
1211
1276
  end
1212
1277
  end
1213
1278
 
1214
- class FXTGAIcon
1279
+ class FXICOIcon
1215
1280
  alias old_initialize initialize
1216
1281
  def initialize(a, *args, &blk)
1217
1282
  argument_names = %w{pix clr opts width height}
@@ -1225,25 +1290,11 @@ module Fox
1225
1290
  end
1226
1291
  end
1227
1292
 
1228
- class FXFontSelector
1229
- alias old_initialize initialize
1230
- def initialize(p, *args, &blk)
1231
- argument_names = %w{target selector opts x y width height}
1232
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1233
- params = {}
1234
- params = args.pop if args.last.is_a? Hash
1235
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1236
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1237
- params = default_params.merge(params)
1238
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1239
- end
1240
- end
1241
-
1242
- class FXDial
1293
+ class FXTabBar
1243
1294
  alias old_initialize initialize
1244
1295
  def initialize(p, *args, &blk)
1245
1296
  argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1246
- default_params = { :target => nil, :selector => 0, :opts => DIAL_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1297
+ default_params = { :target => nil, :selector => 0, :opts => TABBOOK_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING }
1247
1298
  params = {}
1248
1299
  params = args.pop if args.last.is_a? Hash
1249
1300
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1257,25 +1308,29 @@ module Fox
1257
1308
  end
1258
1309
  end
1259
1310
 
1260
- class FXGIFCursor
1311
+ class FXCheckButton
1261
1312
  alias old_initialize initialize
1262
- def initialize(a, pix, *args, &blk)
1263
- argument_names = %w{hx hy}
1264
- default_params = { :hx => -1, :hy => -1 }
1313
+ def initialize(parent, text, *args, &blk)
1314
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1315
+ default_params = { :target => nil, :selector => 0, :opts => CHECKBUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1265
1316
  params = {}
1266
1317
  params = args.pop if args.last.is_a? Hash
1267
1318
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1319
+ if params.key? :padding
1320
+ value = params.delete(:padding)
1321
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1322
+ end
1268
1323
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1269
1324
  params = default_params.merge(params)
1270
- old_initialize(a, pix, params[:hx], params[:hy], &blk)
1325
+ old_initialize(parent, text, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1271
1326
  end
1272
1327
  end
1273
1328
 
1274
- class FXSlider
1329
+ class FXRealSlider
1275
1330
  alias old_initialize initialize
1276
1331
  def initialize(p, *args, &blk)
1277
1332
  argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1278
- default_params = { :target => nil, :selector => 0, :opts => SLIDER_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
1333
+ default_params = { :target => nil, :selector => 0, :opts => REALSLIDER_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
1279
1334
  params = {}
1280
1335
  params = args.pop if args.last.is_a? Hash
1281
1336
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1289,39 +1344,35 @@ module Fox
1289
1344
  end
1290
1345
  end
1291
1346
 
1292
- class FXTableItem
1347
+ class FXMenuRadio
1293
1348
  alias old_initialize initialize
1294
- def initialize(text, *args, &blk)
1295
- argument_names = %w{icon data}
1296
- default_params = { :icon => nil, :data => nil }
1349
+ def initialize(p, text, *args, &blk)
1350
+ argument_names = %w{target selector opts}
1351
+ default_params = { :target => nil, :selector => 0, :opts => 0 }
1297
1352
  params = {}
1298
1353
  params = args.pop if args.last.is_a? Hash
1299
1354
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1300
1355
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1301
1356
  params = default_params.merge(params)
1302
- old_initialize(text, params[:icon], params[:data], &blk)
1357
+ old_initialize(p, text, params[:target], params[:selector], params[:opts], &blk)
1303
1358
  end
1304
1359
  end
1305
1360
 
1306
- class FXTable
1361
+ class FXXPMImage
1307
1362
  alias old_initialize initialize
1308
- def initialize(p, *args, &blk)
1309
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1310
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_MARGIN, :padRight => DEFAULT_MARGIN, :padTop => DEFAULT_MARGIN, :padBottom => DEFAULT_MARGIN }
1363
+ def initialize(a, *args, &blk)
1364
+ argument_names = %w{pix opts width height}
1365
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
1311
1366
  params = {}
1312
1367
  params = args.pop if args.last.is_a? Hash
1313
1368
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1314
- if params.key? :padding
1315
- value = params.delete(:padding)
1316
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1317
- end
1318
1369
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1319
1370
  params = default_params.merge(params)
1320
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1371
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
1321
1372
  end
1322
1373
  end
1323
1374
 
1324
- class FXPNGImage
1375
+ class FXTIFImage
1325
1376
  alias old_initialize initialize
1326
1377
  def initialize(a, *args, &blk)
1327
1378
  argument_names = %w{pix opts width height}
@@ -1335,11 +1386,43 @@ module Fox
1335
1386
  end
1336
1387
  end
1337
1388
 
1338
- class FXStatusBar
1389
+ class FXRadioButton
1390
+ alias old_initialize initialize
1391
+ def initialize(parent, text, *args, &blk)
1392
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1393
+ default_params = { :target => nil, :selector => 0, :opts => RADIOBUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1394
+ params = {}
1395
+ params = args.pop if args.last.is_a? Hash
1396
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1397
+ if params.key? :padding
1398
+ value = params.delete(:padding)
1399
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1400
+ end
1401
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1402
+ params = default_params.merge(params)
1403
+ old_initialize(parent, text, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1404
+ end
1405
+ end
1406
+
1407
+ class FXMDIClient
1339
1408
  alias old_initialize initialize
1340
1409
  def initialize(p, *args, &blk)
1341
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1342
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 3, :padRight => 3, :padTop => 2, :padBottom => 2, :hSpacing => 4, :vSpacing => 0 }
1410
+ argument_names = %w{opts x y width height}
1411
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1412
+ params = {}
1413
+ params = args.pop if args.last.is_a? Hash
1414
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1415
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1416
+ params = default_params.merge(params)
1417
+ old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1418
+ end
1419
+ end
1420
+
1421
+ class FXText
1422
+ alias old_initialize initialize
1423
+ def initialize(p, *args, &blk)
1424
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1425
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 3, :padRight => 3, :padTop => 2, :padBottom => 2 }
1343
1426
  params = {}
1344
1427
  params = args.pop if args.last.is_a? Hash
1345
1428
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1349,7 +1432,18 @@ module Fox
1349
1432
  end
1350
1433
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1351
1434
  params = default_params.merge(params)
1352
- old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1435
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1436
+ end
1437
+ alias old_findText findText
1438
+ def findText(string, *args)
1439
+ argument_names = %w{start flags}
1440
+ default_params = { :start => 0, :flags => SEARCH_FORWARD|SEARCH_WRAP|SEARCH_EXACT }
1441
+ params = {}
1442
+ params = args.pop if args.last.is_a? Hash
1443
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1444
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1445
+ params = default_params.merge(params)
1446
+ old_findText(string, params[:start], params[:flags])
1353
1447
  end
1354
1448
  end
1355
1449
 
@@ -1367,11 +1461,11 @@ module Fox
1367
1461
  end
1368
1462
  end
1369
1463
 
1370
- class FXMatrix
1464
+ class FXButton
1371
1465
  alias old_initialize initialize
1372
- def initialize(parent, *args, &blk)
1373
- argument_names = %w{n opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1374
- default_params = { :n => 1, :opts => MATRIX_BY_ROWS, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1466
+ def initialize(parent, text, *args, &blk)
1467
+ argument_names = %w{icon target selector opts x y width height padLeft padRight padTop padBottom}
1468
+ default_params = { :icon => nil, :target => nil, :selector => 0, :opts => BUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1375
1469
  params = {}
1376
1470
  params = args.pop if args.last.is_a? Hash
1377
1471
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1381,15 +1475,15 @@ module Fox
1381
1475
  end
1382
1476
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1383
1477
  params = default_params.merge(params)
1384
- old_initialize(parent, params[:n], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1478
+ old_initialize(parent, text, params[:icon], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1385
1479
  end
1386
1480
  end
1387
1481
 
1388
- class FXWizard
1482
+ class FXArrowButton
1389
1483
  alias old_initialize initialize
1390
- def initialize(owner, name, image, *args, &blk)
1391
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1392
- default_params = { :opts => DECOR_TITLE|DECOR_BORDER|DECOR_RESIZE, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 10, :padRight => 10, :padTop => 10, :padBottom => 10, :hSpacing => 10, :vSpacing => 10 }
1484
+ def initialize(parent, *args, &blk)
1485
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1486
+ default_params = { :target => nil, :selector => 0, :opts => ARROW_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1393
1487
  params = {}
1394
1488
  params = args.pop if args.last.is_a? Hash
1395
1489
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1399,15 +1493,15 @@ module Fox
1399
1493
  end
1400
1494
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1401
1495
  params = default_params.merge(params)
1402
- old_initialize(owner, name, image, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1496
+ old_initialize(parent, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1403
1497
  end
1404
1498
  end
1405
1499
 
1406
- class FXGradientBar
1500
+ class FXTreeListBox
1407
1501
  alias old_initialize initialize
1408
1502
  def initialize(p, *args, &blk)
1409
1503
  argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1410
- default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1504
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_SUNKEN|FRAME_THICK|TREELISTBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1411
1505
  params = {}
1412
1506
  params = args.pop if args.last.is_a? Hash
1413
1507
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1421,81 +1515,89 @@ module Fox
1421
1515
  end
1422
1516
  end
1423
1517
 
1424
- class FXXBMIcon
1518
+ class FXFontSelector
1425
1519
  alias old_initialize initialize
1426
- def initialize(a, *args, &blk)
1427
- argument_names = %w{pixels mask clr opts width height}
1428
- default_params = { :pixels => nil, :mask => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
1520
+ def initialize(p, *args, &blk)
1521
+ argument_names = %w{target selector opts x y width height}
1522
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1429
1523
  params = {}
1430
1524
  params = args.pop if args.last.is_a? Hash
1431
1525
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1432
1526
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1433
1527
  params = default_params.merge(params)
1434
- old_initialize(a, params[:pixels], params[:mask], params[:clr], params[:opts], params[:width], params[:height], &blk)
1528
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1435
1529
  end
1436
1530
  end
1437
1531
 
1438
- class FXMenuPane
1532
+ class FXListBox
1439
1533
  alias old_initialize initialize
1440
- def initialize(owner, *args, &blk)
1441
- argument_names = %w{opts}
1442
- default_params = { :opts => 0 }
1534
+ def initialize(p, *args, &blk)
1535
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1536
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_SUNKEN|FRAME_THICK|LISTBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1443
1537
  params = {}
1444
1538
  params = args.pop if args.last.is_a? Hash
1445
1539
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1540
+ if params.key? :padding
1541
+ value = params.delete(:padding)
1542
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1543
+ end
1446
1544
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1447
1545
  params = default_params.merge(params)
1448
- old_initialize(owner, params[:opts], &blk)
1546
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1449
1547
  end
1450
1548
  end
1451
1549
 
1452
- class FXVisual
1550
+ class FX7Segment
1453
1551
  alias old_initialize initialize
1454
- def initialize(a, flgs, *args, &blk)
1455
- argument_names = %w{d}
1456
- default_params = { :d => 32 }
1552
+ def initialize(p, text, *args, &blk)
1553
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
1554
+ default_params = { :opts => SEVENSEGMENT_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1457
1555
  params = {}
1458
1556
  params = args.pop if args.last.is_a? Hash
1459
1557
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1558
+ if params.key? :padding
1559
+ value = params.delete(:padding)
1560
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1561
+ end
1460
1562
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1461
1563
  params = default_params.merge(params)
1462
- old_initialize(a, flgs, params[:d], &blk)
1564
+ old_initialize(p, text, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1463
1565
  end
1464
1566
  end
1465
1567
 
1466
- class FXColorDialog
1568
+ class FXMenuPane
1467
1569
  alias old_initialize initialize
1468
- def initialize(owner, title, *args, &blk)
1469
- argument_names = %w{opts x y width height}
1470
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1570
+ def initialize(owner, *args, &blk)
1571
+ argument_names = %w{opts}
1572
+ default_params = { :opts => 0 }
1471
1573
  params = {}
1472
1574
  params = args.pop if args.last.is_a? Hash
1473
1575
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1474
1576
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1475
1577
  params = default_params.merge(params)
1476
- old_initialize(owner, title, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1578
+ old_initialize(owner, params[:opts], &blk)
1477
1579
  end
1478
1580
  end
1479
1581
 
1480
- class FXMDIChild
1582
+ class FXIconDict
1481
1583
  alias old_initialize initialize
1482
- def initialize(p, name, *args, &blk)
1483
- argument_names = %w{ic pup opts x y width height}
1484
- default_params = { :ic => nil, :pup => nil, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1584
+ def initialize(app, *args, &blk)
1585
+ argument_names = %w{path}
1586
+ default_params = { :path => FXIconDict.defaultIconPath }
1485
1587
  params = {}
1486
1588
  params = args.pop if args.last.is_a? Hash
1487
1589
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1488
1590
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1489
1591
  params = default_params.merge(params)
1490
- old_initialize(p, name, params[:ic], params[:pup], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1592
+ old_initialize(app, params[:path], &blk)
1491
1593
  end
1492
1594
  end
1493
1595
 
1494
- class FXPacker
1596
+ class FXTabBook
1495
1597
  alias old_initialize initialize
1496
- def initialize(parent, *args, &blk)
1497
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1498
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1598
+ def initialize(p, *args, &blk)
1599
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1600
+ default_params = { :target => nil, :selector => 0, :opts => TABBOOK_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING }
1499
1601
  params = {}
1500
1602
  params = args.pop if args.last.is_a? Hash
1501
1603
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1505,93 +1607,89 @@ module Fox
1505
1607
  end
1506
1608
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1507
1609
  params = default_params.merge(params)
1508
- old_initialize(parent, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1610
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1509
1611
  end
1510
1612
  end
1511
1613
 
1512
- class FXMessageBox
1614
+ class FXRGBIcon
1513
1615
  alias old_initialize initialize
1514
- def initialize(owner, caption, text, *args, &blk)
1515
- argument_names = %w{ic opts x y}
1516
- default_params = { :ic => nil, :opts => 0, :x => 0, :y => 0 }
1616
+ def initialize(a, *args, &blk)
1617
+ argument_names = %w{pix clr opts width height}
1618
+ default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
1517
1619
  params = {}
1518
1620
  params = args.pop if args.last.is_a? Hash
1519
1621
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1520
1622
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1521
1623
  params = default_params.merge(params)
1522
- old_initialize(owner, caption, text, params[:ic], params[:opts], params[:x], params[:y], &blk)
1624
+ old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
1523
1625
  end
1524
1626
  end
1525
1627
 
1526
- class FXShutterItem
1628
+ class FXToolBarTab
1527
1629
  alias old_initialize initialize
1528
1630
  def initialize(p, *args, &blk)
1529
- argument_names = %w{text icon opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1530
- default_params = { :text => "", :icon => nil, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1631
+ argument_names = %w{target selector opts x y width height}
1632
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1531
1633
  params = {}
1532
1634
  params = args.pop if args.last.is_a? Hash
1533
1635
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1534
- if params.key? :padding
1535
- value = params.delete(:padding)
1536
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1537
- end
1538
1636
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1539
1637
  params = default_params.merge(params)
1540
- old_initialize(p, params[:text], params[:icon], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1638
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1541
1639
  end
1542
1640
  end
1543
1641
 
1544
- class FXShutter
1642
+ class FXXBMIcon
1545
1643
  alias old_initialize initialize
1546
- def initialize(p, *args, &blk)
1547
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1548
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1644
+ def initialize(a, *args, &blk)
1645
+ argument_names = %w{pixels mask clr opts width height}
1646
+ default_params = { :pixels => nil, :mask => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
1549
1647
  params = {}
1550
1648
  params = args.pop if args.last.is_a? Hash
1551
1649
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1552
- if params.key? :padding
1553
- value = params.delete(:padding)
1554
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1555
- end
1556
1650
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1557
1651
  params = default_params.merge(params)
1558
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1652
+ old_initialize(a, params[:pixels], params[:mask], params[:clr], params[:opts], params[:width], params[:height], &blk)
1559
1653
  end
1560
1654
  end
1561
1655
 
1562
- class FXFileDict
1656
+ class FXDial
1563
1657
  alias old_initialize initialize
1564
- def initialize(app, *args, &blk)
1565
- argument_names = %w{db}
1566
- default_params = { :db => nil }
1658
+ def initialize(p, *args, &blk)
1659
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1660
+ default_params = { :target => nil, :selector => 0, :opts => DIAL_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1567
1661
  params = {}
1568
1662
  params = args.pop if args.last.is_a? Hash
1569
1663
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1664
+ if params.key? :padding
1665
+ value = params.delete(:padding)
1666
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1667
+ end
1570
1668
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1571
1669
  params = default_params.merge(params)
1572
- old_initialize(app, params[:db], &blk)
1670
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1573
1671
  end
1574
1672
  end
1575
1673
 
1576
- class FXGIFIcon
1674
+ class FXDelegator
1577
1675
  alias old_initialize initialize
1578
- def initialize(a, *args, &blk)
1579
- argument_names = %w{pix clr opts width height}
1580
- default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
1676
+ def initialize(*args, &blk)
1677
+ argument_names = %w{delegate}
1678
+ default_params = { :delegate => nil }
1581
1679
  params = {}
1582
1680
  params = args.pop if args.last.is_a? Hash
1583
1681
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1584
1682
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1585
1683
  params = default_params.merge(params)
1586
- old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
1684
+ old_initialize(params[:delegate], &blk)
1587
1685
  end
1588
1686
  end
1589
1687
 
1590
- class FXDriveBox
1688
+ class FXMainWindow
1591
1689
  alias old_initialize initialize
1592
- def initialize(p, *args, &blk)
1593
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1594
- default_params = { :target => nil, :selector => 0, :opts => FRAME_SUNKEN|FRAME_THICK|LISTBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1690
+ def initialize(app, title, *args, &blk)
1691
+ argument_names = %w{icon miniIcon opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1692
+ default_params = { :icon => nil, :miniIcon => nil, :opts => DECOR_ALL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0, :hSpacing => 4, :vSpacing => 4 }
1595
1693
  params = {}
1596
1694
  params = args.pop if args.last.is_a? Hash
1597
1695
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1601,43 +1699,47 @@ module Fox
1601
1699
  end
1602
1700
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1603
1701
  params = default_params.merge(params)
1604
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1702
+ old_initialize(app, title, params[:icon], params[:miniIcon], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1605
1703
  end
1606
1704
  end
1607
1705
 
1608
- class FXScrollArea
1706
+ class FXMatrix
1609
1707
  alias old_initialize initialize
1610
1708
  def initialize(parent, *args, &blk)
1611
- argument_names = %w{opts x y width height}
1612
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1709
+ argument_names = %w{n opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
1710
+ default_params = { :n => 1, :opts => MATRIX_BY_ROWS, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
1613
1711
  params = {}
1614
1712
  params = args.pop if args.last.is_a? Hash
1615
1713
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1714
+ if params.key? :padding
1715
+ value = params.delete(:padding)
1716
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1717
+ end
1616
1718
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1617
1719
  params = default_params.merge(params)
1618
- old_initialize(parent, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1720
+ old_initialize(parent, params[:n], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
1619
1721
  end
1620
1722
  end
1621
1723
 
1622
- class FXICOImage
1724
+ class FXColorItem
1623
1725
  alias old_initialize initialize
1624
- def initialize(a, *args, &blk)
1625
- argument_names = %w{pix opts width height}
1626
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
1726
+ def initialize(text, clr, *args, &blk)
1727
+ argument_names = %w{data}
1728
+ default_params = { :data => nil }
1627
1729
  params = {}
1628
1730
  params = args.pop if args.last.is_a? Hash
1629
1731
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1630
1732
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1631
1733
  params = default_params.merge(params)
1632
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
1734
+ old_initialize(text, clr, params[:data], &blk)
1633
1735
  end
1634
1736
  end
1635
1737
 
1636
- class FXDirSelector
1738
+ class FXColorList
1637
1739
  alias old_initialize initialize
1638
1740
  def initialize(p, *args, &blk)
1639
1741
  argument_names = %w{target selector opts x y width height}
1640
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1742
+ default_params = { :target => nil, :selector => 0, :opts => LIST_BROWSESELECT, :x => 0, :y => 0, :width => 0, :height => 0 }
1641
1743
  params = {}
1642
1744
  params = args.pop if args.last.is_a? Hash
1643
1745
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1647,133 +1749,85 @@ module Fox
1647
1749
  end
1648
1750
  end
1649
1751
 
1650
- class FXToolBarGrip
1752
+ class FXRuler
1651
1753
  alias old_initialize initialize
1652
1754
  def initialize(p, *args, &blk)
1653
- argument_names = %w{target selector opts x y width height}
1654
- default_params = { :target => nil, :selector => 0, :opts => TOOLBARGRIP_SINGLE, :x => 0, :y => 0, :width => 0, :height => 0 }
1755
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1756
+ default_params = { :target => nil, :selector => 0, :opts => RULER_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1655
1757
  params = {}
1656
1758
  params = args.pop if args.last.is_a? Hash
1657
1759
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1760
+ if params.key? :padding
1761
+ value = params.delete(:padding)
1762
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1763
+ end
1658
1764
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1659
1765
  params = default_params.merge(params)
1660
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1766
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1661
1767
  end
1662
1768
  end
1663
1769
 
1664
- class FXMDIDeleteButton
1770
+ class FXScrollWindow
1665
1771
  alias old_initialize initialize
1666
1772
  def initialize(p, *args, &blk)
1667
- argument_names = %w{target selector opts x y width height}
1668
- default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1669
- params = {}
1670
- params = args.pop if args.last.is_a? Hash
1671
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1672
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1673
- params = default_params.merge(params)
1674
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1675
- end
1676
- end
1677
-
1678
- class FXMDIRestoreButton
1679
- alias old_initialize initialize
1680
- def initialize(p, *args, &blk)
1681
- argument_names = %w{target selector opts x y width height}
1682
- default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1683
- params = {}
1684
- params = args.pop if args.last.is_a? Hash
1685
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1686
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1687
- params = default_params.merge(params)
1688
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1689
- end
1690
- end
1691
-
1692
- class FXMDIMaximizeButton
1693
- alias old_initialize initialize
1694
- def initialize(p, *args, &blk)
1695
- argument_names = %w{target selector opts x y width height}
1696
- default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1697
- params = {}
1698
- params = args.pop if args.last.is_a? Hash
1699
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1700
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1701
- params = default_params.merge(params)
1702
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1703
- end
1704
- end
1705
-
1706
- class FXMDIMinimizeButton
1707
- alias old_initialize initialize
1708
- def initialize(p, *args, &blk)
1709
- argument_names = %w{target selector opts x y width height}
1710
- default_params = { :target => nil, :selector => 0, :opts => FRAME_RAISED, :x => 0, :y => 0, :width => 0, :height => 0 }
1711
- params = {}
1712
- params = args.pop if args.last.is_a? Hash
1713
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1714
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1715
- params = default_params.merge(params)
1716
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1717
- end
1718
- end
1719
-
1720
- class FXMDIWindowButton
1721
- alias old_initialize initialize
1722
- def initialize(p, pup, *args, &blk)
1723
- argument_names = %w{target selector opts x y width height}
1724
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1773
+ argument_names = %w{opts x y width height}
1774
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1725
1775
  params = {}
1726
1776
  params = args.pop if args.last.is_a? Hash
1727
1777
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1728
1778
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1729
1779
  params = default_params.merge(params)
1730
- old_initialize(p, pup, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1780
+ old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1731
1781
  end
1732
1782
  end
1733
1783
 
1734
- class FXMDIMenu
1784
+ class FXPPMImage
1735
1785
  alias old_initialize initialize
1736
- def initialize(owner, *args, &blk)
1737
- argument_names = %w{target}
1738
- default_params = { :target => nil }
1786
+ def initialize(a, *args, &blk)
1787
+ argument_names = %w{pix opts width height}
1788
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
1739
1789
  params = {}
1740
1790
  params = args.pop if args.last.is_a? Hash
1741
1791
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1742
1792
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1743
1793
  params = default_params.merge(params)
1744
- old_initialize(owner, params[:target], &blk)
1794
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
1745
1795
  end
1746
1796
  end
1747
1797
 
1748
- class FXTIFIcon
1798
+ class FXLabel
1749
1799
  alias old_initialize initialize
1750
- def initialize(a, *args, &blk)
1751
- argument_names = %w{pix clr opts width height}
1752
- default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
1800
+ def initialize(parent, text, *args, &blk)
1801
+ argument_names = %w{icon opts x y width height padLeft padRight padTop padBottom}
1802
+ default_params = { :icon => nil, :opts => LABEL_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1753
1803
  params = {}
1754
1804
  params = args.pop if args.last.is_a? Hash
1755
1805
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1806
+ if params.key? :padding
1807
+ value = params.delete(:padding)
1808
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1809
+ end
1756
1810
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1757
1811
  params = default_params.merge(params)
1758
- old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
1812
+ old_initialize(parent, text, params[:icon], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1759
1813
  end
1760
1814
  end
1761
1815
 
1762
- class FXDirItem
1816
+ class FXFileItem
1763
1817
  alias old_initialize initialize
1764
1818
  def initialize(text, *args, &blk)
1765
- argument_names = %w{oi ci data}
1766
- default_params = { :oi => nil, :ci => nil, :data => nil }
1819
+ argument_names = %w{bi mi ptr}
1820
+ default_params = { :bi => nil, :mi => nil, :ptr => nil }
1767
1821
  params = {}
1768
1822
  params = args.pop if args.last.is_a? Hash
1769
1823
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1770
1824
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1771
1825
  params = default_params.merge(params)
1772
- old_initialize(text, params[:oi], params[:ci], params[:data], &blk)
1826
+ old_initialize(text, params[:bi], params[:mi], params[:ptr], &blk)
1773
1827
  end
1774
1828
  end
1775
1829
 
1776
- class FXDirList
1830
+ class FXFileList
1777
1831
  alias old_initialize initialize
1778
1832
  def initialize(p, *args, &blk)
1779
1833
  argument_names = %w{target selector opts x y width height}
@@ -1787,53 +1841,43 @@ module Fox
1787
1841
  end
1788
1842
  end
1789
1843
 
1790
- class FXPCXImage
1844
+ class FXComboBox
1791
1845
  alias old_initialize initialize
1792
- def initialize(a, *args, &blk)
1793
- argument_names = %w{pix opts width height}
1794
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
1846
+ def initialize(p, cols, *args, &blk)
1847
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1848
+ default_params = { :target => nil, :selector => 0, :opts => COMBOBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1795
1849
  params = {}
1796
1850
  params = args.pop if args.last.is_a? Hash
1797
1851
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1852
+ if params.key? :padding
1853
+ value = params.delete(:padding)
1854
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1855
+ end
1798
1856
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1799
1857
  params = default_params.merge(params)
1800
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
1858
+ old_initialize(p, cols, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1801
1859
  end
1802
1860
  end
1803
1861
 
1804
- class FXCanvas
1862
+ class FXToolBarGrip
1805
1863
  alias old_initialize initialize
1806
- def initialize(parent, *args, &blk)
1864
+ def initialize(p, *args, &blk)
1807
1865
  argument_names = %w{target selector opts x y width height}
1808
- default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
1809
- params = {}
1810
- params = args.pop if args.last.is_a? Hash
1811
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1812
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1813
- params = default_params.merge(params)
1814
- old_initialize(parent, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1815
- end
1816
- end
1817
-
1818
- class FXDataTarget
1819
- alias old_initialize initialize
1820
- def initialize(*args, &blk)
1821
- argument_names = %w{value target selector}
1822
- default_params = { :value => nil, :target => nil, :selector => 0 }
1866
+ default_params = { :target => nil, :selector => 0, :opts => TOOLBARGRIP_SINGLE, :x => 0, :y => 0, :width => 0, :height => 0 }
1823
1867
  params = {}
1824
1868
  params = args.pop if args.last.is_a? Hash
1825
1869
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1826
1870
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1827
1871
  params = default_params.merge(params)
1828
- old_initialize(params[:value], params[:target], params[:selector], &blk)
1872
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1829
1873
  end
1830
1874
  end
1831
1875
 
1832
- class FXTabBar
1876
+ class FXKnob
1833
1877
  alias old_initialize initialize
1834
1878
  def initialize(p, *args, &blk)
1835
1879
  argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1836
- default_params = { :target => nil, :selector => 0, :opts => TABBOOK_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING }
1880
+ default_params = { :target => nil, :selector => 0, :opts => KNOB_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1837
1881
  params = {}
1838
1882
  params = args.pop if args.last.is_a? Hash
1839
1883
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1847,25 +1891,29 @@ module Fox
1847
1891
  end
1848
1892
  end
1849
1893
 
1850
- class FXPCXIcon
1894
+ class FXOption
1851
1895
  alias old_initialize initialize
1852
- def initialize(a, *args, &blk)
1853
- argument_names = %w{pix clr opts width height}
1854
- default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
1896
+ def initialize(p, text, *args, &blk)
1897
+ argument_names = %w{ic target selector opts x y width height padLeft padRight padTop padBottom}
1898
+ default_params = { :ic => nil, :target => nil, :selector => 0, :opts => JUSTIFY_NORMAL|ICON_BEFORE_TEXT, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1855
1899
  params = {}
1856
1900
  params = args.pop if args.last.is_a? Hash
1857
1901
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1902
+ if params.key? :padding
1903
+ value = params.delete(:padding)
1904
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1905
+ end
1858
1906
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1859
1907
  params = default_params.merge(params)
1860
- old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
1908
+ old_initialize(p, text, params[:ic], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1861
1909
  end
1862
1910
  end
1863
1911
 
1864
- class FXToggleButton
1912
+ class FXOptionMenu
1865
1913
  alias old_initialize initialize
1866
- def initialize(p, text1, text2, *args, &blk)
1867
- argument_names = %w{icon1 icon2 target selector opts x y width height padLeft padRight padTop padBottom}
1868
- default_params = { :icon1 => nil, :icon2 => nil, :target => nil, :selector => 0, :opts => TOGGLEBUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1914
+ def initialize(p, *args, &blk)
1915
+ argument_names = %w{pup opts x y width height padLeft padRight padTop padBottom}
1916
+ default_params = { :pup => nil, :opts => JUSTIFY_NORMAL|ICON_BEFORE_TEXT, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1869
1917
  params = {}
1870
1918
  params = args.pop if args.last.is_a? Hash
1871
1919
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1875,15 +1923,15 @@ module Fox
1875
1923
  end
1876
1924
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1877
1925
  params = default_params.merge(params)
1878
- old_initialize(p, text1, text2, params[:icon1], params[:icon2], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1926
+ old_initialize(p, params[:pup], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1879
1927
  end
1880
1928
  end
1881
1929
 
1882
- class FXFrame
1930
+ class FXDriveBox
1883
1931
  alias old_initialize initialize
1884
- def initialize(parent, *args, &blk)
1885
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
1886
- default_params = { :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1932
+ def initialize(p, *args, &blk)
1933
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1934
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_SUNKEN|FRAME_THICK|LISTBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1887
1935
  params = {}
1888
1936
  params = args.pop if args.last.is_a? Hash
1889
1937
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1893,89 +1941,85 @@ module Fox
1893
1941
  end
1894
1942
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1895
1943
  params = default_params.merge(params)
1896
- old_initialize(parent, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1944
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
1897
1945
  end
1898
1946
  end
1899
1947
 
1900
- class FXToolTip
1948
+ class FXInputDialog
1901
1949
  alias old_initialize initialize
1902
- def initialize(app, *args, &blk)
1903
- argument_names = %w{opts x y width height}
1904
- default_params = { :opts => TOOLTIP_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
1950
+ def initialize(owner, caption, label, *args, &blk)
1951
+ argument_names = %w{icon opts x y width height}
1952
+ default_params = { :icon => nil, :opts => INPUTDIALOG_STRING, :x => 0, :y => 0, :width => 0, :height => 0 }
1905
1953
  params = {}
1906
1954
  params = args.pop if args.last.is_a? Hash
1907
1955
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1908
1956
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1909
1957
  params = default_params.merge(params)
1910
- old_initialize(app, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1958
+ old_initialize(owner, caption, label, params[:icon], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1911
1959
  end
1912
1960
  end
1913
1961
 
1914
- class FXMenuCaption
1962
+ class FXTGAImage
1915
1963
  alias old_initialize initialize
1916
- def initialize(parent, text, *args, &blk)
1917
- argument_names = %w{icon opts}
1918
- default_params = { :icon => nil, :opts => 0 }
1964
+ def initialize(a, *args, &blk)
1965
+ argument_names = %w{pix opts width height}
1966
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
1919
1967
  params = {}
1920
1968
  params = args.pop if args.last.is_a? Hash
1921
1969
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1922
1970
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1923
1971
  params = default_params.merge(params)
1924
- old_initialize(parent, text, params[:icon], params[:opts], &blk)
1972
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
1925
1973
  end
1926
1974
  end
1927
1975
 
1928
- class FXBitmap
1976
+ class FXJPGIcon
1929
1977
  alias old_initialize initialize
1930
- def initialize(app, *args, &blk)
1931
- argument_names = %w{pixels opts width height}
1932
- default_params = { :pixels => nil, :opts => 0, :width => 1, :height => 1 }
1978
+ def initialize(a, *args, &blk)
1979
+ argument_names = %w{pix clr opts width height quality}
1980
+ default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1, :quality => 75 }
1933
1981
  params = {}
1934
1982
  params = args.pop if args.last.is_a? Hash
1935
1983
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1936
1984
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1937
1985
  params = default_params.merge(params)
1938
- old_initialize(app, params[:pixels], params[:opts], params[:width], params[:height], &blk)
1986
+ old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], params[:quality], &blk)
1939
1987
  end
1940
1988
  end
1941
1989
 
1942
- class FX7Segment
1990
+ class FXScrollArea
1943
1991
  alias old_initialize initialize
1944
- def initialize(p, text, *args, &blk)
1945
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
1946
- default_params = { :opts => SEVENSEGMENT_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
1992
+ def initialize(parent, *args, &blk)
1993
+ argument_names = %w{opts x y width height}
1994
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
1947
1995
  params = {}
1948
1996
  params = args.pop if args.last.is_a? Hash
1949
1997
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1950
- if params.key? :padding
1951
- value = params.delete(:padding)
1952
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
1953
- end
1954
1998
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1955
1999
  params = default_params.merge(params)
1956
- old_initialize(p, text, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2000
+ old_initialize(parent, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
1957
2001
  end
1958
2002
  end
1959
2003
 
1960
- class FXPopup
2004
+ class FXTableItem
1961
2005
  alias old_initialize initialize
1962
- def initialize(owner, *args, &blk)
1963
- argument_names = %w{opts x y width height}
1964
- default_params = { :opts => POPUP_VERTICAL|FRAME_RAISED|FRAME_THICK, :x => 0, :y => 0, :width => 0, :height => 0 }
2006
+ def initialize(text, *args, &blk)
2007
+ argument_names = %w{icon data}
2008
+ default_params = { :icon => nil, :data => nil }
1965
2009
  params = {}
1966
2010
  params = args.pop if args.last.is_a? Hash
1967
2011
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
1968
2012
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
1969
2013
  params = default_params.merge(params)
1970
- old_initialize(owner, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2014
+ old_initialize(text, params[:icon], params[:data], &blk)
1971
2015
  end
1972
2016
  end
1973
2017
 
1974
- class FXListBox
2018
+ class FXTable
1975
2019
  alias old_initialize initialize
1976
2020
  def initialize(p, *args, &blk)
1977
2021
  argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
1978
- default_params = { :target => nil, :selector => 0, :opts => FRAME_SUNKEN|FRAME_THICK|LISTBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2022
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_MARGIN, :padRight => DEFAULT_MARGIN, :padTop => DEFAULT_MARGIN, :padBottom => DEFAULT_MARGIN }
1979
2023
  params = {}
1980
2024
  params = args.pop if args.last.is_a? Hash
1981
2025
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -1989,131 +2033,123 @@ module Fox
1989
2033
  end
1990
2034
  end
1991
2035
 
1992
- class FXMenuCheck
2036
+ class FXGLContext
1993
2037
  alias old_initialize initialize
1994
- def initialize(p, text, *args, &blk)
1995
- argument_names = %w{target selector opts}
1996
- default_params = { :target => nil, :selector => 0, :opts => 0 }
2038
+ def initialize(app, visual, *args, &blk)
2039
+ argument_names = %w{other}
2040
+ default_params = { :other => nil }
1997
2041
  params = {}
1998
2042
  params = args.pop if args.last.is_a? Hash
1999
2043
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2000
2044
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2001
2045
  params = default_params.merge(params)
2002
- old_initialize(p, text, params[:target], params[:selector], params[:opts], &blk)
2046
+ old_initialize(app, visual, params[:other], &blk)
2003
2047
  end
2004
2048
  end
2005
2049
 
2006
- class FXMenuCascade
2050
+ class FXMenuSeparator
2007
2051
  alias old_initialize initialize
2008
- def initialize(parent, text, *args, &blk)
2009
- argument_names = %w{icon popupMenu opts}
2010
- default_params = { :icon => nil, :popupMenu => nil, :opts => 0 }
2052
+ def initialize(parent, *args, &blk)
2053
+ argument_names = %w{opts}
2054
+ default_params = { :opts => 0 }
2011
2055
  params = {}
2012
2056
  params = args.pop if args.last.is_a? Hash
2013
2057
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2014
2058
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2015
2059
  params = default_params.merge(params)
2016
- old_initialize(parent, text, params[:icon], params[:popupMenu], params[:opts], &blk)
2060
+ old_initialize(parent, params[:opts], &blk)
2017
2061
  end
2018
2062
  end
2019
2063
 
2020
- class FXPPMImage
2064
+ class FXRulerView
2021
2065
  alias old_initialize initialize
2022
- def initialize(a, *args, &blk)
2023
- argument_names = %w{pix opts width height}
2024
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
2066
+ def initialize(p, *args, &blk)
2067
+ argument_names = %w{target selector opts x y width height}
2068
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2025
2069
  params = {}
2026
2070
  params = args.pop if args.last.is_a? Hash
2027
2071
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2028
2072
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2029
2073
  params = default_params.merge(params)
2030
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
2074
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2031
2075
  end
2032
2076
  end
2033
2077
 
2034
- class FXTextField
2078
+ class FXCanvas
2035
2079
  alias old_initialize initialize
2036
- def initialize(p, ncols, *args, &blk)
2037
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2038
- default_params = { :target => nil, :selector => 0, :opts => TEXTFIELD_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2080
+ def initialize(parent, *args, &blk)
2081
+ argument_names = %w{target selector opts x y width height}
2082
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
2039
2083
  params = {}
2040
2084
  params = args.pop if args.last.is_a? Hash
2041
2085
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2042
- if params.key? :padding
2043
- value = params.delete(:padding)
2044
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2045
- end
2046
2086
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2047
2087
  params = default_params.merge(params)
2048
- old_initialize(p, ncols, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2088
+ old_initialize(parent, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2049
2089
  end
2050
2090
  end
2051
2091
 
2052
- class FXHeaderItem
2092
+ class FXFileStream
2053
2093
  alias old_initialize initialize
2054
- def initialize(text, *args, &blk)
2055
- argument_names = %w{ic s ptr}
2056
- default_params = { :ic => nil, :s => 0, :ptr => nil }
2094
+ def initialize(*args, &blk)
2095
+ argument_names = %w{cont}
2096
+ default_params = { :cont => nil }
2057
2097
  params = {}
2058
2098
  params = args.pop if args.last.is_a? Hash
2059
2099
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2060
2100
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2061
2101
  params = default_params.merge(params)
2062
- old_initialize(text, params[:ic], params[:s], params[:ptr], &blk)
2102
+ old_initialize(params[:cont], &blk)
2063
2103
  end
2064
2104
  end
2065
2105
 
2066
- class FXHeader
2106
+ class FXICOImage
2067
2107
  alias old_initialize initialize
2068
- def initialize(p, *args, &blk)
2069
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2070
- default_params = { :target => nil, :selector => 0, :opts => HEADER_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2108
+ def initialize(a, *args, &blk)
2109
+ argument_names = %w{pix opts width height}
2110
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
2071
2111
  params = {}
2072
2112
  params = args.pop if args.last.is_a? Hash
2073
2113
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2074
- if params.key? :padding
2075
- value = params.delete(:padding)
2076
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2077
- end
2078
2114
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2079
2115
  params = default_params.merge(params)
2080
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2116
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
2081
2117
  end
2082
2118
  end
2083
2119
 
2084
- class FXDelegator
2120
+ class FXImage
2085
2121
  alias old_initialize initialize
2086
- def initialize(*args, &blk)
2087
- argument_names = %w{delegate}
2088
- default_params = { :delegate => nil }
2122
+ def initialize(a, *args, &blk)
2123
+ argument_names = %w{pixels opts width height}
2124
+ default_params = { :pixels => nil, :opts => 0, :width => 1, :height => 1 }
2089
2125
  params = {}
2090
2126
  params = args.pop if args.last.is_a? Hash
2091
2127
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2092
2128
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2093
2129
  params = default_params.merge(params)
2094
- old_initialize(params[:delegate], &blk)
2130
+ old_initialize(a, params[:pixels], params[:opts], params[:width], params[:height], &blk)
2095
2131
  end
2096
2132
  end
2097
2133
 
2098
- class FXDirDialog
2134
+ class FXColorDialog
2099
2135
  alias old_initialize initialize
2100
- def initialize(owner, name, *args, &blk)
2136
+ def initialize(owner, title, *args, &blk)
2101
2137
  argument_names = %w{opts x y width height}
2102
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 500, :height => 300 }
2138
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2103
2139
  params = {}
2104
2140
  params = args.pop if args.last.is_a? Hash
2105
2141
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2106
2142
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2107
2143
  params = default_params.merge(params)
2108
- old_initialize(owner, name, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2144
+ old_initialize(owner, title, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2109
2145
  end
2110
2146
  end
2111
2147
 
2112
- class FXRealSpinner
2148
+ class FXHorizontalFrame
2113
2149
  alias old_initialize initialize
2114
- def initialize(p, cols, *args, &blk)
2115
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2116
- default_params = { :target => nil, :selector => 0, :opts => REALSPIN_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2150
+ def initialize(p, *args, &blk)
2151
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
2152
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
2117
2153
  params = {}
2118
2154
  params = args.pop if args.last.is_a? Hash
2119
2155
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2123,113 +2159,101 @@ module Fox
2123
2159
  end
2124
2160
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2125
2161
  params = default_params.merge(params)
2126
- old_initialize(p, cols, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2127
- end
2128
- end
2129
-
2130
- class FXFileDialog
2131
- alias old_initialize initialize
2132
- def initialize(owner, name, *args, &blk)
2133
- argument_names = %w{opts x y width height}
2134
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 500, :height => 300 }
2135
- params = {}
2136
- params = args.pop if args.last.is_a? Hash
2137
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2138
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2139
- params = default_params.merge(params)
2140
- old_initialize(owner, name, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2162
+ old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
2141
2163
  end
2142
2164
  end
2143
2165
 
2144
- class FXIconDict
2166
+ class FXToggleButton
2145
2167
  alias old_initialize initialize
2146
- def initialize(app, *args, &blk)
2147
- argument_names = %w{path}
2148
- default_params = { :path => FXIconDict.defaultIconPath }
2168
+ def initialize(p, text1, text2, *args, &blk)
2169
+ argument_names = %w{icon1 icon2 target selector opts x y width height padLeft padRight padTop padBottom}
2170
+ default_params = { :icon1 => nil, :icon2 => nil, :target => nil, :selector => 0, :opts => TOGGLEBUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2149
2171
  params = {}
2150
2172
  params = args.pop if args.last.is_a? Hash
2151
2173
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2174
+ if params.key? :padding
2175
+ value = params.delete(:padding)
2176
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2177
+ end
2152
2178
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2153
2179
  params = default_params.merge(params)
2154
- old_initialize(app, params[:path], &blk)
2180
+ old_initialize(p, text1, text2, params[:icon1], params[:icon2], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2155
2181
  end
2156
2182
  end
2157
2183
 
2158
- class FXScintilla
2184
+ class FXColorWheel
2159
2185
  alias old_initialize initialize
2160
2186
  def initialize(p, *args, &blk)
2161
- argument_names = %w{target selector opts x y width height}
2162
- default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2187
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2188
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2163
2189
  params = {}
2164
2190
  params = args.pop if args.last.is_a? Hash
2165
2191
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2192
+ if params.key? :padding
2193
+ value = params.delete(:padding)
2194
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2195
+ end
2166
2196
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2167
2197
  params = default_params.merge(params)
2168
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2198
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2169
2199
  end
2170
2200
  end
2171
2201
 
2172
- class FXIcon
2202
+ class FXDockSite
2173
2203
  alias old_initialize initialize
2174
- def initialize(app, *args, &blk)
2175
- argument_names = %w{pix clr opts width height}
2176
- default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
2204
+ def initialize(p, *args, &blk)
2205
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
2206
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0, :hSpacing => 0, :vSpacing => 0 }
2177
2207
  params = {}
2178
2208
  params = args.pop if args.last.is_a? Hash
2179
2209
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2210
+ if params.key? :padding
2211
+ value = params.delete(:padding)
2212
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2213
+ end
2180
2214
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2181
2215
  params = default_params.merge(params)
2182
- old_initialize(app, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
2216
+ old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
2183
2217
  end
2184
2218
  end
2185
2219
 
2186
- class FXJPGIcon
2220
+ class FXGIFImage
2187
2221
  alias old_initialize initialize
2188
2222
  def initialize(a, *args, &blk)
2189
- argument_names = %w{pix clr opts width height quality}
2190
- default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1, :quality => 75 }
2191
- params = {}
2192
- params = args.pop if args.last.is_a? Hash
2193
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2194
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2195
- params = default_params.merge(params)
2196
- old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], params[:quality], &blk)
2197
- end
2198
- end
2199
-
2200
- class FXMenuRadio
2201
- alias old_initialize initialize
2202
- def initialize(p, text, *args, &blk)
2203
- argument_names = %w{target selector opts}
2204
- default_params = { :target => nil, :selector => 0, :opts => 0 }
2223
+ argument_names = %w{pix opts width height}
2224
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
2205
2225
  params = {}
2206
2226
  params = args.pop if args.last.is_a? Hash
2207
2227
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2208
2228
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2209
2229
  params = default_params.merge(params)
2210
- old_initialize(p, text, params[:target], params[:selector], params[:opts], &blk)
2230
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
2211
2231
  end
2212
2232
  end
2213
2233
 
2214
- class FXBMPIcon
2234
+ class FXFrame
2215
2235
  alias old_initialize initialize
2216
- def initialize(a, *args, &blk)
2217
- argument_names = %w{pix clr opts width height}
2218
- default_params = { :pix => nil, :clr => FXRGB(192,192,192), :opts => 0, :width => 1, :height => 1 }
2236
+ def initialize(parent, *args, &blk)
2237
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
2238
+ default_params = { :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2219
2239
  params = {}
2220
2240
  params = args.pop if args.last.is_a? Hash
2221
2241
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2242
+ if params.key? :padding
2243
+ value = params.delete(:padding)
2244
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2245
+ end
2222
2246
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2223
2247
  params = default_params.merge(params)
2224
- old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
2248
+ old_initialize(parent, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2225
2249
  end
2226
2250
  end
2227
2251
 
2228
- class FXPicker
2252
+ class FXTabItem
2229
2253
  alias old_initialize initialize
2230
2254
  def initialize(p, text, *args, &blk)
2231
- argument_names = %w{ic target selector opts x y width height padLeft padRight padTop padBottom}
2232
- default_params = { :ic => nil, :target => nil, :selector => 0, :opts => BUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2255
+ argument_names = %w{ic opts x y width height padLeft padRight padTop padBottom}
2256
+ default_params = { :ic => nil, :opts => TAB_TOP_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2233
2257
  params = {}
2234
2258
  params = args.pop if args.last.is_a? Hash
2235
2259
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2239,29 +2263,29 @@ module Fox
2239
2263
  end
2240
2264
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2241
2265
  params = default_params.merge(params)
2242
- old_initialize(p, text, params[:ic], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2266
+ old_initialize(p, text, params[:ic], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2243
2267
  end
2244
2268
  end
2245
2269
 
2246
- class FXChoiceBox
2270
+ class FXStatusLine
2247
2271
  alias old_initialize initialize
2248
- def initialize(owner, caption, text, icon, choices, *args, &blk)
2249
- argument_names = %w{opts x y width height}
2250
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2272
+ def initialize(p, *args, &blk)
2273
+ argument_names = %w{target selector}
2274
+ default_params = { :target => nil, :selector => 0 }
2251
2275
  params = {}
2252
2276
  params = args.pop if args.last.is_a? Hash
2253
2277
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2254
2278
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2255
2279
  params = default_params.merge(params)
2256
- old_initialize(owner, caption, text, icon, choices, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2280
+ old_initialize(p, params[:target], params[:selector], &blk)
2257
2281
  end
2258
2282
  end
2259
2283
 
2260
- class FXDirBox
2284
+ class FXSpinner
2261
2285
  alias old_initialize initialize
2262
- def initialize(p, *args, &blk)
2286
+ def initialize(p, cols, *args, &blk)
2263
2287
  argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2264
- default_params = { :target => nil, :selector => 0, :opts => FRAME_SUNKEN|FRAME_THICK|TREELISTBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2288
+ default_params = { :target => nil, :selector => 0, :opts => SPIN_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2265
2289
  params = {}
2266
2290
  params = args.pop if args.last.is_a? Hash
2267
2291
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2271,103 +2295,85 @@ module Fox
2271
2295
  end
2272
2296
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2273
2297
  params = default_params.merge(params)
2274
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2275
- end
2276
- end
2277
-
2278
- class FXICOIcon
2279
- alias old_initialize initialize
2280
- def initialize(a, *args, &blk)
2281
- argument_names = %w{pix clr opts width height}
2282
- default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
2283
- params = {}
2284
- params = args.pop if args.last.is_a? Hash
2285
- args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2286
- params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2287
- params = default_params.merge(params)
2288
- old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
2298
+ old_initialize(p, cols, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2289
2299
  end
2290
2300
  end
2291
2301
 
2292
- class FXPNGIcon
2302
+ class FXDataTarget
2293
2303
  alias old_initialize initialize
2294
- def initialize(a, *args, &blk)
2295
- argument_names = %w{pix clr opts width height}
2296
- default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
2304
+ def initialize(*args, &blk)
2305
+ argument_names = %w{value target selector}
2306
+ default_params = { :value => nil, :target => nil, :selector => 0 }
2297
2307
  params = {}
2298
2308
  params = args.pop if args.last.is_a? Hash
2299
2309
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2300
2310
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2301
2311
  params = default_params.merge(params)
2302
- old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
2312
+ old_initialize(params[:value], params[:target], params[:selector], &blk)
2303
2313
  end
2304
2314
  end
2305
2315
 
2306
- class FXRealSlider
2316
+ class FXSplashWindow
2307
2317
  alias old_initialize initialize
2308
- def initialize(p, *args, &blk)
2309
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2310
- default_params = { :target => nil, :selector => 0, :opts => REALSLIDER_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
2318
+ def initialize(owner, icon, *args, &blk)
2319
+ argument_names = %w{opts ms}
2320
+ default_params = { :opts => SPLASH_SIMPLE, :ms => 5000 }
2311
2321
  params = {}
2312
2322
  params = args.pop if args.last.is_a? Hash
2313
2323
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2314
- if params.key? :padding
2315
- value = params.delete(:padding)
2316
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2317
- end
2318
2324
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2319
2325
  params = default_params.merge(params)
2320
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2326
+ old_initialize(owner, icon, params[:opts], params[:ms], &blk)
2321
2327
  end
2322
2328
  end
2323
2329
 
2324
- class FXImageView
2330
+ class FXMessageBox
2325
2331
  alias old_initialize initialize
2326
- def initialize(p, *args, &blk)
2327
- argument_names = %w{img target selector opts x y width height}
2328
- default_params = { :img => nil, :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2332
+ def initialize(owner, caption, text, *args, &blk)
2333
+ argument_names = %w{ic opts x y}
2334
+ default_params = { :ic => nil, :opts => 0, :x => 0, :y => 0 }
2329
2335
  params = {}
2330
2336
  params = args.pop if args.last.is_a? Hash
2331
2337
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2332
2338
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2333
2339
  params = default_params.merge(params)
2334
- old_initialize(p, params[:img], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2340
+ old_initialize(owner, caption, text, params[:ic], params[:opts], params[:x], params[:y], &blk)
2335
2341
  end
2336
2342
  end
2337
2343
 
2338
- class FXStatusLine
2344
+ class FXPNGIcon
2339
2345
  alias old_initialize initialize
2340
- def initialize(p, *args, &blk)
2341
- argument_names = %w{target selector}
2342
- default_params = { :target => nil, :selector => 0 }
2346
+ def initialize(a, *args, &blk)
2347
+ argument_names = %w{pix clr opts width height}
2348
+ default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
2343
2349
  params = {}
2344
2350
  params = args.pop if args.last.is_a? Hash
2345
2351
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2346
2352
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2347
2353
  params = default_params.merge(params)
2348
- old_initialize(p, params[:target], params[:selector], &blk)
2354
+ old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
2349
2355
  end
2350
2356
  end
2351
2357
 
2352
- class FXSearchDialog
2358
+ class FXPNGImage
2353
2359
  alias old_initialize initialize
2354
- def initialize(owner, caption, *args, &blk)
2355
- argument_names = %w{ic opts x y width height}
2356
- default_params = { :ic => nil, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2360
+ def initialize(a, *args, &blk)
2361
+ argument_names = %w{pix opts width height}
2362
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
2357
2363
  params = {}
2358
2364
  params = args.pop if args.last.is_a? Hash
2359
2365
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2360
2366
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2361
2367
  params = default_params.merge(params)
2362
- old_initialize(owner, caption, params[:ic], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2368
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
2363
2369
  end
2364
2370
  end
2365
2371
 
2366
- class FXProgressBar
2372
+ class FXWizard
2367
2373
  alias old_initialize initialize
2368
- def initialize(p, *args, &blk)
2369
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2370
- default_params = { :target => nil, :selector => 0, :opts => PROGRESSBAR_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2374
+ def initialize(owner, name, image, *args, &blk)
2375
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
2376
+ default_params = { :opts => DECOR_TITLE|DECOR_BORDER|DECOR_RESIZE, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 10, :padRight => 10, :padTop => 10, :padBottom => 10, :hSpacing => 10, :vSpacing => 10 }
2371
2377
  params = {}
2372
2378
  params = args.pop if args.last.is_a? Hash
2373
2379
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2377,57 +2383,61 @@ module Fox
2377
2383
  end
2378
2384
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2379
2385
  params = default_params.merge(params)
2380
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2386
+ old_initialize(owner, name, image, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
2381
2387
  end
2382
2388
  end
2383
2389
 
2384
- class FXComposite
2390
+ class FXBMPIcon
2385
2391
  alias old_initialize initialize
2386
- def initialize(parent, *args, &blk)
2387
- argument_names = %w{opts x y width height}
2388
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2392
+ def initialize(a, *args, &blk)
2393
+ argument_names = %w{pix clr opts width height}
2394
+ default_params = { :pix => nil, :clr => FXRGB(192,192,192), :opts => 0, :width => 1, :height => 1 }
2389
2395
  params = {}
2390
2396
  params = args.pop if args.last.is_a? Hash
2391
2397
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2392
2398
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2393
2399
  params = default_params.merge(params)
2394
- old_initialize(parent, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2400
+ old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
2395
2401
  end
2396
2402
  end
2397
2403
 
2398
- class FXSplashWindow
2404
+ class FXGradientBar
2399
2405
  alias old_initialize initialize
2400
- def initialize(owner, icon, *args, &blk)
2401
- argument_names = %w{opts ms}
2402
- default_params = { :opts => SPLASH_SIMPLE, :ms => 5000 }
2406
+ def initialize(p, *args, &blk)
2407
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2408
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2403
2409
  params = {}
2404
2410
  params = args.pop if args.last.is_a? Hash
2405
2411
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2412
+ if params.key? :padding
2413
+ value = params.delete(:padding)
2414
+ [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2415
+ end
2406
2416
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2407
2417
  params = default_params.merge(params)
2408
- old_initialize(owner, icon, params[:opts], params[:ms], &blk)
2418
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2409
2419
  end
2410
2420
  end
2411
2421
 
2412
- class FXMenuCommand
2422
+ class FXPPMIcon
2413
2423
  alias old_initialize initialize
2414
- def initialize(p, text, *args, &blk)
2415
- argument_names = %w{ic target selector opts}
2416
- default_params = { :ic => nil, :target => nil, :selector => 0, :opts => 0 }
2424
+ def initialize(a, *args, &blk)
2425
+ argument_names = %w{pix clr opts width height}
2426
+ default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
2417
2427
  params = {}
2418
2428
  params = args.pop if args.last.is_a? Hash
2419
2429
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2420
2430
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2421
2431
  params = default_params.merge(params)
2422
- old_initialize(p, text, params[:ic], params[:target], params[:selector], params[:opts], &blk)
2432
+ old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
2423
2433
  end
2424
2434
  end
2425
2435
 
2426
- class FXTabItem
2436
+ class FXTriStateButton
2427
2437
  alias old_initialize initialize
2428
- def initialize(p, text, *args, &blk)
2429
- argument_names = %w{ic opts x y width height padLeft padRight padTop padBottom}
2430
- default_params = { :ic => nil, :opts => TAB_TOP_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2438
+ def initialize(p, text1, text2, text3, *args, &blk)
2439
+ argument_names = %w{icon1 icon2 icon3 target selector opts x y width height padLeft padRight padTop padBottom}
2440
+ default_params = { :icon1 => nil, :icon2 => nil, :icon3 => nil, :target => nil, :selector => 0, :opts => TOGGLEBUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2431
2441
  params = {}
2432
2442
  params = args.pop if args.last.is_a? Hash
2433
2443
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2437,175 +2447,155 @@ module Fox
2437
2447
  end
2438
2448
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2439
2449
  params = default_params.merge(params)
2440
- old_initialize(p, text, params[:ic], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2450
+ old_initialize(p, text1, text2, text3, params[:icon1], params[:icon2], params[:icon3], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2441
2451
  end
2442
2452
  end
2443
2453
 
2444
- class FXColorWheel
2454
+ class FXPCXImage
2445
2455
  alias old_initialize initialize
2446
- def initialize(p, *args, &blk)
2447
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2448
- default_params = { :target => nil, :selector => 0, :opts => FRAME_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2456
+ def initialize(a, *args, &blk)
2457
+ argument_names = %w{pix opts width height}
2458
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
2449
2459
  params = {}
2450
2460
  params = args.pop if args.last.is_a? Hash
2451
2461
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2452
- if params.key? :padding
2453
- value = params.delete(:padding)
2454
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2455
- end
2456
2462
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2457
2463
  params = default_params.merge(params)
2458
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2464
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
2459
2465
  end
2460
2466
  end
2461
2467
 
2462
- class FXMemoryStream
2468
+ class FXXBMImage
2463
2469
  alias old_initialize initialize
2464
- def initialize(*args, &blk)
2465
- argument_names = %w{cont}
2466
- default_params = { :cont => nil }
2470
+ def initialize(a, *args, &blk)
2471
+ argument_names = %w{pixels mask opts width height}
2472
+ default_params = { :pixels => nil, :mask => nil, :opts => 0, :width => 1, :height => 1 }
2467
2473
  params = {}
2468
2474
  params = args.pop if args.last.is_a? Hash
2469
2475
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2470
2476
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2471
2477
  params = default_params.merge(params)
2472
- old_initialize(params[:cont], &blk)
2478
+ old_initialize(a, params[:pixels], params[:mask], params[:opts], params[:width], params[:height], &blk)
2473
2479
  end
2474
2480
  end
2475
2481
 
2476
- class FXImageFrame
2482
+ class FXColorSelector
2477
2483
  alias old_initialize initialize
2478
- def initialize(p, img, *args, &blk)
2479
- argument_names = %w{opts x y width height padLeft padRight padTop padBottom}
2480
- default_params = { :opts => FRAME_SUNKEN|FRAME_THICK, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 0, :padRight => 0, :padTop => 0, :padBottom => 0 }
2484
+ def initialize(parent, *args, &blk)
2485
+ argument_names = %w{target selector opts x y width height}
2486
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2481
2487
  params = {}
2482
2488
  params = args.pop if args.last.is_a? Hash
2483
2489
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2484
- if params.key? :padding
2485
- value = params.delete(:padding)
2486
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2487
- end
2488
2490
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2489
2491
  params = default_params.merge(params)
2490
- old_initialize(p, img, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2492
+ old_initialize(parent, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2491
2493
  end
2492
2494
  end
2493
2495
 
2494
- class FXImage
2496
+ class FXMenuTitle
2495
2497
  alias old_initialize initialize
2496
- def initialize(a, *args, &blk)
2497
- argument_names = %w{pixels opts width height}
2498
- default_params = { :pixels => nil, :opts => 0, :width => 1, :height => 1 }
2498
+ def initialize(parent, text, *args, &blk)
2499
+ argument_names = %w{icon popupMenu opts}
2500
+ default_params = { :icon => nil, :popupMenu => nil, :opts => 0 }
2499
2501
  params = {}
2500
2502
  params = args.pop if args.last.is_a? Hash
2501
2503
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2502
2504
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2503
2505
  params = default_params.merge(params)
2504
- old_initialize(a, params[:pixels], params[:opts], params[:width], params[:height], &blk)
2506
+ old_initialize(parent, text, params[:icon], params[:popupMenu], params[:opts], &blk)
2505
2507
  end
2506
2508
  end
2507
2509
 
2508
- class FXTriStateButton
2510
+ class FXMenuCheck
2509
2511
  alias old_initialize initialize
2510
- def initialize(p, text1, text2, text3, *args, &blk)
2511
- argument_names = %w{icon1 icon2 icon3 target selector opts x y width height padLeft padRight padTop padBottom}
2512
- default_params = { :icon1 => nil, :icon2 => nil, :icon3 => nil, :target => nil, :selector => 0, :opts => TOGGLEBUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2512
+ def initialize(p, text, *args, &blk)
2513
+ argument_names = %w{target selector opts}
2514
+ default_params = { :target => nil, :selector => 0, :opts => 0 }
2513
2515
  params = {}
2514
2516
  params = args.pop if args.last.is_a? Hash
2515
2517
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2516
- if params.key? :padding
2517
- value = params.delete(:padding)
2518
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2519
- end
2520
2518
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2521
2519
  params = default_params.merge(params)
2522
- old_initialize(p, text1, text2, text3, params[:icon1], params[:icon2], params[:icon3], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2520
+ old_initialize(p, text, params[:target], params[:selector], params[:opts], &blk)
2523
2521
  end
2524
2522
  end
2525
2523
 
2526
- class FXJPGImage
2524
+ class FXDirSelector
2527
2525
  alias old_initialize initialize
2528
- def initialize(a, *args, &blk)
2529
- argument_names = %w{pix opts width height quality}
2530
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1, :quality => 75 }
2526
+ def initialize(p, *args, &blk)
2527
+ argument_names = %w{target selector opts x y width height}
2528
+ default_params = { :target => nil, :selector => 0, :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2531
2529
  params = {}
2532
2530
  params = args.pop if args.last.is_a? Hash
2533
2531
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2534
2532
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2535
2533
  params = default_params.merge(params)
2536
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], params[:quality], &blk)
2534
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2537
2535
  end
2538
2536
  end
2539
2537
 
2540
- class FXKnob
2538
+ class FXFileDict
2541
2539
  alias old_initialize initialize
2542
- def initialize(p, *args, &blk)
2543
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2544
- default_params = { :target => nil, :selector => 0, :opts => KNOB_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2540
+ def initialize(app, *args, &blk)
2541
+ argument_names = %w{db}
2542
+ default_params = { :db => nil }
2545
2543
  params = {}
2546
2544
  params = args.pop if args.last.is_a? Hash
2547
2545
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2548
- if params.key? :padding
2549
- value = params.delete(:padding)
2550
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2551
- end
2552
2546
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2553
2547
  params = default_params.merge(params)
2554
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2548
+ old_initialize(app, params[:db], &blk)
2555
2549
  end
2556
2550
  end
2557
2551
 
2558
- class FXTreeListBox
2552
+ class FXVisual
2559
2553
  alias old_initialize initialize
2560
- def initialize(p, *args, &blk)
2561
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2562
- default_params = { :target => nil, :selector => 0, :opts => FRAME_SUNKEN|FRAME_THICK|TREELISTBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2554
+ def initialize(a, flgs, *args, &blk)
2555
+ argument_names = %w{d}
2556
+ default_params = { :d => 32 }
2563
2557
  params = {}
2564
2558
  params = args.pop if args.last.is_a? Hash
2565
2559
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2566
- if params.key? :padding
2567
- value = params.delete(:padding)
2568
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2569
- end
2570
2560
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2571
2561
  params = default_params.merge(params)
2572
- old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2562
+ old_initialize(a, flgs, params[:d], &blk)
2573
2563
  end
2574
2564
  end
2575
2565
 
2576
- class FXPrintDialog
2566
+ class FXMemoryStream
2577
2567
  alias old_initialize initialize
2578
- def initialize(owner, name, *args, &blk)
2579
- argument_names = %w{opts x y width height}
2580
- default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0 }
2568
+ def initialize(*args, &blk)
2569
+ argument_names = %w{cont}
2570
+ default_params = { :cont => nil }
2581
2571
  params = {}
2582
2572
  params = args.pop if args.last.is_a? Hash
2583
2573
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2584
2574
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2585
2575
  params = default_params.merge(params)
2586
- old_initialize(owner, name, params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2576
+ old_initialize(params[:cont], &blk)
2587
2577
  end
2588
2578
  end
2589
2579
 
2590
- class FXTIFImage
2580
+ class FXXPMIcon
2591
2581
  alias old_initialize initialize
2592
2582
  def initialize(a, *args, &blk)
2593
- argument_names = %w{pix opts width height}
2594
- default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1 }
2583
+ argument_names = %w{pix clr opts width height}
2584
+ default_params = { :pix => nil, :clr => 0, :opts => 0, :width => 1, :height => 1 }
2595
2585
  params = {}
2596
2586
  params = args.pop if args.last.is_a? Hash
2597
2587
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2598
2588
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2599
2589
  params = default_params.merge(params)
2600
- old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], &blk)
2590
+ old_initialize(a, params[:pix], params[:clr], params[:opts], params[:width], params[:height], &blk)
2601
2591
  end
2602
2592
  end
2603
2593
 
2604
- class FXRadioButton
2594
+ class FXVerticalFrame
2605
2595
  alias old_initialize initialize
2606
- def initialize(parent, text, *args, &blk)
2607
- argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2608
- default_params = { :target => nil, :selector => 0, :opts => RADIOBUTTON_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2596
+ def initialize(p, *args, &blk)
2597
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
2598
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
2609
2599
  params = {}
2610
2600
  params = args.pop if args.last.is_a? Hash
2611
2601
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2615,11 +2605,11 @@ module Fox
2615
2605
  end
2616
2606
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2617
2607
  params = default_params.merge(params)
2618
- old_initialize(parent, text, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2608
+ old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
2619
2609
  end
2620
2610
  end
2621
2611
 
2622
- class FXFileSelector
2612
+ class FXScintilla
2623
2613
  alias old_initialize initialize
2624
2614
  def initialize(p, *args, &blk)
2625
2615
  argument_names = %w{target selector opts x y width height}
@@ -2633,25 +2623,25 @@ module Fox
2633
2623
  end
2634
2624
  end
2635
2625
 
2636
- class FXMenuSeparator
2626
+ class FXJPGImage
2637
2627
  alias old_initialize initialize
2638
- def initialize(parent, *args, &blk)
2639
- argument_names = %w{opts}
2640
- default_params = { :opts => 0 }
2628
+ def initialize(a, *args, &blk)
2629
+ argument_names = %w{pix opts width height quality}
2630
+ default_params = { :pix => nil, :opts => 0, :width => 1, :height => 1, :quality => 75 }
2641
2631
  params = {}
2642
2632
  params = args.pop if args.last.is_a? Hash
2643
2633
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2644
2634
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2645
2635
  params = default_params.merge(params)
2646
- old_initialize(parent, params[:opts], &blk)
2636
+ old_initialize(a, params[:pix], params[:opts], params[:width], params[:height], params[:quality], &blk)
2647
2637
  end
2648
2638
  end
2649
2639
 
2650
- class FXGroupBox
2640
+ class FXDialogBox
2651
2641
  alias old_initialize initialize
2652
- def initialize(parent, text, *args, &blk)
2642
+ def initialize(owner, title, *args, &blk)
2653
2643
  argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
2654
- default_params = { :opts => GROUPBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING, :hSpacing => DEFAULT_SPACING, :vSpacing => DEFAULT_SPACING }
2644
+ default_params = { :opts => DECOR_TITLE|DECOR_BORDER, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 10, :padRight => 10, :padTop => 10, :padBottom => 10, :hSpacing => 4, :vSpacing => 4 }
2655
2645
  params = {}
2656
2646
  params = args.pop if args.last.is_a? Hash
2657
2647
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2661,15 +2651,15 @@ module Fox
2661
2651
  end
2662
2652
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2663
2653
  params = default_params.merge(params)
2664
- old_initialize(parent, text, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
2654
+ old_initialize(owner, title, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
2665
2655
  end
2666
2656
  end
2667
2657
 
2668
- class FXMenuButton
2658
+ class FXDirBox
2669
2659
  alias old_initialize initialize
2670
- def initialize(parent, text, *args, &blk)
2671
- argument_names = %w{icon popupMenu opts x y width height padLeft padRight padTop padBottom}
2672
- default_params = { :icon => nil, :popupMenu => nil, :opts => JUSTIFY_NORMAL|ICON_BEFORE_TEXT|MENUBUTTON_DOWN, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_SPACING, :padRight => DEFAULT_SPACING, :padTop => DEFAULT_SPACING, :padBottom => DEFAULT_SPACING }
2660
+ def initialize(p, *args, &blk)
2661
+ argument_names = %w{target selector opts x y width height padLeft padRight padTop padBottom}
2662
+ default_params = { :target => nil, :selector => 0, :opts => FRAME_SUNKEN|FRAME_THICK|TREELISTBOX_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2673
2663
  params = {}
2674
2664
  params = args.pop if args.last.is_a? Hash
2675
2665
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2679,47 +2669,57 @@ module Fox
2679
2669
  end
2680
2670
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2681
2671
  params = default_params.merge(params)
2682
- old_initialize(parent, text, params[:icon], params[:popupMenu], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2672
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2683
2673
  end
2684
2674
  end
2685
2675
 
2686
- class FXGLContext
2676
+ class FXApp
2687
2677
  alias old_initialize initialize
2688
- def initialize(app, visual, *args, &blk)
2689
- argument_names = %w{other}
2690
- default_params = { :other => nil }
2678
+ def initialize(*args, &blk)
2679
+ argument_names = %w{appName vendorName}
2680
+ default_params = { :appName => "Application", :vendorName => "FoxDefault" }
2691
2681
  params = {}
2692
2682
  params = args.pop if args.last.is_a? Hash
2693
2683
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2694
2684
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2695
2685
  params = default_params.merge(params)
2696
- old_initialize(app, visual, params[:other], &blk)
2686
+ old_initialize(params[:appName], params[:vendorName], &blk)
2697
2687
  end
2698
2688
  end
2699
2689
 
2700
- class FXOption
2690
+ class FXListItem
2701
2691
  alias old_initialize initialize
2702
- def initialize(p, text, *args, &blk)
2703
- argument_names = %w{ic target selector opts x y width height padLeft padRight padTop padBottom}
2704
- default_params = { :ic => nil, :target => nil, :selector => 0, :opts => JUSTIFY_NORMAL|ICON_BEFORE_TEXT, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2692
+ def initialize(text, *args, &blk)
2693
+ argument_names = %w{icon data}
2694
+ default_params = { :icon => nil, :data => nil }
2705
2695
  params = {}
2706
2696
  params = args.pop if args.last.is_a? Hash
2707
2697
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2708
- if params.key? :padding
2709
- value = params.delete(:padding)
2710
- [:padLeft, :padRight, :padTop, :padBottom].each { |s| params[s] ||= value }
2711
- end
2712
2698
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2713
2699
  params = default_params.merge(params)
2714
- old_initialize(p, text, params[:ic], params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2700
+ old_initialize(text, params[:icon], params[:data], &blk)
2715
2701
  end
2716
2702
  end
2717
2703
 
2718
- class FXOptionMenu
2704
+ class FXList
2719
2705
  alias old_initialize initialize
2720
2706
  def initialize(p, *args, &blk)
2721
- argument_names = %w{pup opts x y width height padLeft padRight padTop padBottom}
2722
- default_params = { :pup => nil, :opts => JUSTIFY_NORMAL|ICON_BEFORE_TEXT, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => DEFAULT_PAD, :padRight => DEFAULT_PAD, :padTop => DEFAULT_PAD, :padBottom => DEFAULT_PAD }
2707
+ argument_names = %w{target selector opts x y width height}
2708
+ default_params = { :target => nil, :selector => 0, :opts => LIST_NORMAL, :x => 0, :y => 0, :width => 0, :height => 0 }
2709
+ params = {}
2710
+ params = args.pop if args.last.is_a? Hash
2711
+ args.each_with_index { |e, i| params[argument_names[i].intern] = e }
2712
+ params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2713
+ params = default_params.merge(params)
2714
+ old_initialize(p, params[:target], params[:selector], params[:opts], params[:x], params[:y], params[:width], params[:height], &blk)
2715
+ end
2716
+ end
2717
+
2718
+ class FXStatusBar
2719
+ alias old_initialize initialize
2720
+ def initialize(p, *args, &blk)
2721
+ argument_names = %w{opts x y width height padLeft padRight padTop padBottom hSpacing vSpacing}
2722
+ default_params = { :opts => 0, :x => 0, :y => 0, :width => 0, :height => 0, :padLeft => 3, :padRight => 3, :padTop => 2, :padBottom => 2, :hSpacing => 4, :vSpacing => 0 }
2723
2723
  params = {}
2724
2724
  params = args.pop if args.last.is_a? Hash
2725
2725
  args.each_with_index { |e, i| params[argument_names[i].intern] = e }
@@ -2729,7 +2729,7 @@ module Fox
2729
2729
  end
2730
2730
  params.keys.each { |key| raise ArgumentError, "Unrecognized parameter #{key}" unless default_params.keys.include?(key) }
2731
2731
  params = default_params.merge(params)
2732
- old_initialize(p, params[:pup], params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], &blk)
2732
+ old_initialize(p, params[:opts], params[:x], params[:y], params[:width], params[:height], params[:padLeft], params[:padRight], params[:padTop], params[:padBottom], params[:hSpacing], params[:vSpacing], &blk)
2733
2733
  end
2734
2734
  end
2735
2735