fxruby 1.4.2 → 1.4.3

Sign up to get free protection for your applications and to get access to all the features.
data/doc/apes02.html CHANGED
@@ -1,6 +1,6 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Object Life Cycles and Garbage Collection</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="implementation.html" title="Appendix&nbsp;E.&nbsp;Implementation"><link rel="previous" href="implementation.html" title="Appendix&nbsp;E.&nbsp;Implementation"><link rel="next" href="apes03.html" title="Virtual Functions"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Object Life Cycles and Garbage Collection</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="implementation.html">Prev</a>&nbsp;</td><th width="60%" align="center">Appendix&nbsp;E.&nbsp;Implementation</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="apes03.html">Next</a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4206"></a>Object Life Cycles and Garbage Collection</h2></div></div><div></div></div><p>One of the more difficult issues to deal with was understanding
3
+ <title>Object Life Cycles and Garbage Collection</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="implementation.html" title="Appendix&nbsp;E.&nbsp;Implementation"><link rel="previous" href="implementation.html" title="Appendix&nbsp;E.&nbsp;Implementation"><link rel="next" href="apes03.html" title="Virtual Functions"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Object Life Cycles and Garbage Collection</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="implementation.html">Prev</a>&nbsp;</td><th width="60%" align="center">Appendix&nbsp;E.&nbsp;Implementation</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="apes03.html">Next</a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4291"></a>Object Life Cycles and Garbage Collection</h2></div></div><div></div></div><p>One of the more difficult issues to deal with was understanding
4
4
  the "life cycle" of FOX objects (that is, the actual C++ objects) and
5
5
  their relationship to the associated Ruby instances. Understanding this
6
6
  relationship is critical when dealing with Ruby's garbage collector,
@@ -18,4 +18,4 @@ myButton = FXButton.new(parentWin, "Hello, World!", myIcon)</pre></td></tr></tab
18
18
  returned from most class instance methods; they are references to already-
19
19
  existing objects. For example, <tt class="methodname">FXStatusBar#statusline
20
20
  </tt> returns a reference to the status bar's enclosed status line
21
- instance.</p><div class="section" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="d0e4225"></a>GL Objects</h3></div></div><div></div></div><p>A C++ <tt class="classname">FXGLGroup</tt> object owns all of the <tt class="classname">FXGLObject</tt> objects it "contains". In other words, when that <tt class="classname">FXGLGroup</tt> object is destroyed, it will also destroy all of the <tt class="classname">FXGLObject</tt> objects for which it holds pointers.</p><p>In order to keep track of <span class="emphasis"><em>which</em></span> GL objects have been added to an <tt class="classname">FXGLGroup</tt>, all of the FXRuby C++ classes derived from <tt class="classname">FXGLObject</tt> have a boolean member variable <i class="structfield"><tt>owned</tt></i> that indicates whether this object is "owned" or not. Until an <tt class="classname">FXGLObject</tt> object is added to a group, this member variable should stay false.</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="implementation.html">Prev</a>&nbsp;</td><td width="20%" align="center"><a accesskey="u" href="implementation.html">Up</a></td><td width="40%" align="right">&nbsp;<a accesskey="n" href="apes03.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Appendix&nbsp;E.&nbsp;Implementation&nbsp;</td><td width="20%" align="center"><a accesskey="h" href="book.html">Home</a></td><td width="40%" align="right" valign="top">&nbsp;Virtual Functions</td></tr></table></div></body></html>
21
+ instance.</p><div class="section" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="d0e4310"></a>GL Objects</h3></div></div><div></div></div><p>A C++ <tt class="classname">FXGLGroup</tt> object owns all of the <tt class="classname">FXGLObject</tt> objects it "contains". In other words, when that <tt class="classname">FXGLGroup</tt> object is destroyed, it will also destroy all of the <tt class="classname">FXGLObject</tt> objects for which it holds pointers.</p><p>In order to keep track of <span class="emphasis"><em>which</em></span> GL objects have been added to an <tt class="classname">FXGLGroup</tt>, all of the FXRuby C++ classes derived from <tt class="classname">FXGLObject</tt> have a boolean member variable <i class="structfield"><tt>owned</tt></i> that indicates whether this object is "owned" or not. Until an <tt class="classname">FXGLObject</tt> object is added to a group, this member variable should stay false.</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="implementation.html">Prev</a>&nbsp;</td><td width="20%" align="center"><a accesskey="u" href="implementation.html">Up</a></td><td width="40%" align="right">&nbsp;<a accesskey="n" href="apes03.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Appendix&nbsp;E.&nbsp;Implementation&nbsp;</td><td width="20%" align="center"><a accesskey="h" href="book.html">Home</a></td><td width="40%" align="right" valign="top">&nbsp;Virtual Functions</td></tr></table></div></body></html>
data/doc/apes03.html CHANGED
@@ -1,6 +1,6 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Virtual Functions</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="implementation.html" title="Appendix&nbsp;E.&nbsp;Implementation"><link rel="previous" href="apes02.html" title="Object Life Cycles and Garbage Collection"><link rel="next" href="cvs.html" title="Appendix&nbsp;F.&nbsp;Getting the Sources from CVS"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Virtual Functions</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="apes02.html">Prev</a>&nbsp;</td><th width="60%" align="center">Appendix&nbsp;E.&nbsp;Implementation</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="cvs.html">Next</a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4259"></a>Virtual Functions</h2></div></div><div></div></div><p>
3
+ <title>Virtual Functions</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="implementation.html" title="Appendix&nbsp;E.&nbsp;Implementation"><link rel="previous" href="apes02.html" title="Object Life Cycles and Garbage Collection"><link rel="next" href="cvs.html" title="Appendix&nbsp;F.&nbsp;Getting the Sources from CVS"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Virtual Functions</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="apes02.html">Prev</a>&nbsp;</td><th width="60%" align="center">Appendix&nbsp;E.&nbsp;Implementation</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="cvs.html">Next</a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4344"></a>Virtual Functions</h2></div></div><div></div></div><p>
4
4
  One of the design requirements for FXRuby was to ensure that any
5
5
  virtual function call made on a FOX object (from the C++ library
6
6
  layer) is routed to the proper Ruby instance method, even if that
data/doc/book.html CHANGED
@@ -1,3 +1,3 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Developing Graphical User Interfaces with FXRuby</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="next" href="pt01.html" title="Part&nbsp;I.&nbsp;The Basics"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Developing Graphical User Interfaces with FXRuby</th></tr><tr><td width="20%" align="left">&nbsp;</td><th width="60%" align="center">&nbsp;</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="pt01.html">Next</a></td></tr></table><hr></div><div class="book" lang="en"><div class="titlepage"><div><div><h1 class="title"><a name="book"></a>Developing Graphical User Interfaces with FXRuby</h1></div><div><h2 class="subtitle">Covers FXRuby Version 1.4</h2></div><div><div class="author"><h3 class="author"><span class="firstname">Lyle</span> <span class="surname">Johnson</span></h3></div></div><div><p class="copyright">Copyright &copy; 2001-2005 J. Lyle Johnson</p></div></div><div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt>I. <a href="pt01.html">The Basics</a></dt><dd><dl><dt><a href="goals.html">History and Goals</a></dt><dt>1. <a href="build.html">Building from Source Code</a></dt><dt>2. <a href="gems.html">Installing from Gems</a></dt><dt>3. <a href="tutorial1.html">Hello, World!</a></dt><dd><dl><dt><a href="tutorial1.html#d0e619">First Things First</a></dt><dt><a href="ch03s02.html">Better living through buttons</a></dt><dt><a href="ch03s03.html">Messages</a></dt><dt><a href="ch03s04.html">Adding a tool tip</a></dt><dt><a href="ch03s05.html">Adding an icon</a></dt></dl></dd><dt>4. <a href="clipboardtut.html">Working With the Clipboard</a></dt><dd><dl><dt><a href="clipboardtut.html#d0e1008">Basic Application</a></dt><dt><a href="ch04s02.html">Acquiring the Clipboard</a></dt><dt><a href="ch04s03.html">Sending Data to the Clipboard</a></dt><dt><a href="ch04s04.html">Pasting Data from the Clipboard</a></dt></dl></dd><dt>5. <a href="dragdroptut.html">Drag and Drop</a></dt><dd><dl><dt><a href="dragdroptut.html#d0e1223">Drop Sites</a></dt><dt><a href="ch05s02.html">Drag Sources</a></dt><dt><a href="ch05s03.html">Putting It All Together</a></dt></dl></dd><dt>6. <a href="examples.html">Examples</a></dt><dt>7. <a href="events.html">FXRuby's Message-Target System</a></dt><dt>8. <a href="todo.html">To-do list</a></dt><dt>9. <a href="infosources.html">Other Sources of Information</a></dt><dt>10. <a href="changes.html">Change History</a></dt></dl></dd><dt>II. <a href="pt02.html">Appendices</a></dt><dd><dl><dt>A. <a href="opengl.html">Using OpenGL with FXRuby</a></dt><dt>B. <a href="scintilla.html">Using Scintilla with FXRuby</a></dt><dt>C. <a href="differences.html">Differences between FOX and FXRuby</a></dt><dt>D. <a href="library.html">The FXRuby Standard Library</a></dt><dt>E. <a href="implementation.html">Implementation</a></dt><dd><dl><dt><a href="implementation.html#d0e4187">Code Generation</a></dt><dt><a href="apes02.html">Object Life Cycles and Garbage Collection</a></dt><dd><dl><dt><a href="apes02.html#d0e4225">GL Objects</a></dt></dl></dd><dt><a href="apes03.html">Virtual Functions</a></dt></dl></dd><dt>F. <a href="cvs.html">Getting the Sources from CVS</a></dt></dl></dd></dl></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left">&nbsp;</td><td width="20%" align="center">&nbsp;</td><td width="40%" align="right">&nbsp;<a accesskey="n" href="pt01.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">&nbsp;</td><td width="20%" align="center">&nbsp;</td><td width="40%" align="right" valign="top">&nbsp;Part&nbsp;I.&nbsp;The Basics</td></tr></table></div></body></html>
3
+ <title>Developing Graphical User Interfaces with FXRuby</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="next" href="pt01.html" title="Part&nbsp;I.&nbsp;The Basics"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Developing Graphical User Interfaces with FXRuby</th></tr><tr><td width="20%" align="left">&nbsp;</td><th width="60%" align="center">&nbsp;</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="pt01.html">Next</a></td></tr></table><hr></div><div class="book" lang="en"><div class="titlepage"><div><div><h1 class="title"><a name="book"></a>Developing Graphical User Interfaces with FXRuby</h1></div><div><h2 class="subtitle">Covers FXRuby Version 1.4</h2></div><div><div class="author"><h3 class="author"><span class="firstname">Lyle</span> <span class="surname">Johnson</span></h3></div></div><div><p class="copyright">Copyright &copy; 2001-2005 J. Lyle Johnson</p></div></div><div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt>I. <a href="pt01.html">The Basics</a></dt><dd><dl><dt><a href="goals.html">History and Goals</a></dt><dt>1. <a href="build.html">Building from Source Code</a></dt><dt>2. <a href="gems.html">Installing from Gems</a></dt><dt>3. <a href="tutorial1.html">Hello, World!</a></dt><dd><dl><dt><a href="tutorial1.html#d0e619">First Things First</a></dt><dt><a href="ch03s02.html">Better living through buttons</a></dt><dt><a href="ch03s03.html">Messages</a></dt><dt><a href="ch03s04.html">Adding a tool tip</a></dt><dt><a href="ch03s05.html">Adding an icon</a></dt></dl></dd><dt>4. <a href="clipboardtut.html">Working With the Clipboard</a></dt><dd><dl><dt><a href="clipboardtut.html#d0e1008">Basic Application</a></dt><dt><a href="ch04s02.html">Acquiring the Clipboard</a></dt><dt><a href="ch04s03.html">Sending Data to the Clipboard</a></dt><dt><a href="ch04s04.html">Pasting Data from the Clipboard</a></dt></dl></dd><dt>5. <a href="dragdroptut.html">Drag and Drop</a></dt><dd><dl><dt><a href="dragdroptut.html#d0e1223">Drop Sites</a></dt><dt><a href="ch05s02.html">Drag Sources</a></dt><dt><a href="ch05s03.html">Putting It All Together</a></dt></dl></dd><dt>6. <a href="examples.html">Examples</a></dt><dt>7. <a href="events.html">FXRuby's Message-Target System</a></dt><dt>8. <a href="todo.html">To-do list</a></dt><dt>9. <a href="infosources.html">Other Sources of Information</a></dt><dt>10. <a href="changes.html">Change History</a></dt></dl></dd><dt>II. <a href="pt02.html">Appendices</a></dt><dd><dl><dt>A. <a href="opengl.html">Using OpenGL with FXRuby</a></dt><dt>B. <a href="scintilla.html">Using Scintilla with FXRuby</a></dt><dt>C. <a href="differences.html">Differences between FOX and FXRuby</a></dt><dt>D. <a href="library.html">The FXRuby Standard Library</a></dt><dt>E. <a href="implementation.html">Implementation</a></dt><dd><dl><dt><a href="implementation.html#d0e4272">Code Generation</a></dt><dt><a href="apes02.html">Object Life Cycles and Garbage Collection</a></dt><dd><dl><dt><a href="apes02.html#d0e4310">GL Objects</a></dt></dl></dd><dt><a href="apes03.html">Virtual Functions</a></dt></dl></dd><dt>F. <a href="cvs.html">Getting the Sources from CVS</a></dt></dl></dd></dl></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left">&nbsp;</td><td width="20%" align="center">&nbsp;</td><td width="40%" align="right">&nbsp;<a accesskey="n" href="pt01.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">&nbsp;</td><td width="20%" align="center">&nbsp;</td><td width="40%" align="right" valign="top">&nbsp;Part&nbsp;I.&nbsp;The Basics</td></tr></table></div></body></html>
data/doc/changes.html CHANGED
@@ -1,6 +1,41 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Chapter&nbsp;10.&nbsp;Change History</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt01.html" title="Part&nbsp;I.&nbsp;The Basics"><link rel="previous" href="infosources.html" title="Chapter&nbsp;9.&nbsp;Other Sources of Information"><link rel="next" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter&nbsp;10.&nbsp;Change History</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="infosources.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;I.&nbsp;The Basics</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="pt02.html">Next</a></td></tr></table><hr></div><div class="chapter" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="changes"></a>Chapter&nbsp;10.&nbsp;Change History</h2></div></div><div></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2403"></a>Changes For Version 1.4.2 (August 22, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>Due to a bug in the implementation, the
3
+ <title>Chapter&nbsp;10.&nbsp;Change History</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt01.html" title="Part&nbsp;I.&nbsp;The Basics"><link rel="previous" href="infosources.html" title="Chapter&nbsp;9.&nbsp;Other Sources of Information"><link rel="next" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter&nbsp;10.&nbsp;Change History</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="infosources.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;I.&nbsp;The Basics</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="pt02.html">Next</a></td></tr></table><hr></div><div class="chapter" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="changes"></a>Chapter&nbsp;10.&nbsp;Change History</h2></div></div><div></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2403"></a>Changes For Version 1.4.3 (November 7, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>The <tt class="constant">TOGGLEBUTTON_KEEPSTATE</tt> option for the
4
+ <tt class="classname">FXToggleButton</tt> class was not documented (see
5
+ <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=2286&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
6
+ Bug #2286</a>). This oversight has been corrected. Thanks to Tim
7
+ Smith for reporting this problem.</p></li><li style="list-style-type: disc"><p>The <tt class="filename">scintilla.rb</tt> library file was not up to
8
+ date with the latest FXScintilla release, and as a result it was
9
+ missing some methods (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=2479&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
10
+ Bug #2479</a>). This oversight has been corrected. Thanks to Maxim
11
+ Kulkin for reporting this problem.</p></li><li style="list-style-type: disc"><p>Due to changes in the APIs for timers and chores, the mechanisms
12
+ for removing chores and timeouts were broken (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=2563&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
13
+ Bug #2563</a>). This bug has been fixed. Thanks to "moinker" for
14
+ reporting this problem.</p></li><li style="list-style-type: disc"><p>An error in the test setup caused all of the tests for the
15
+ <tt class="classname">FXList</tt> class to fail (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=2564&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
16
+ Bug #2564</a>). This bug has been fixed. Thanks to Peter for
17
+ reporting this problem.</p></li><li style="list-style-type: disc"><p>Due to a bug in the test suite runner script, not all test cases
18
+ were being exercised (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=2565&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
19
+ Bug #2565</a>). This bug has been fixed.</p></li><li style="list-style-type: disc"><p>Calling the <tt class="methodname">getPixel</tt> method for the
20
+ <tt class="classname">FXImage</tt> class when the client-side pixel buffer
21
+ for the image has already been released would cause a program to crash
22
+ (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=2611&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
23
+ Bug #2611</a>). Now, <tt class="methodname">getPixel</tt> will raise
24
+ an exception if it's called after the pixel buffer has been released.
25
+ The documentation for <tt class="methodname">getPixel</tt> has been
26
+ updated accordingly. Thanks to Gonzalo Garramuno for reporting this
27
+ problem.</p></li><li style="list-style-type: disc"><p>The <tt class="methodname">makePositionVisible</tt> method for the
28
+ <tt class="classname">FXTable</tt> class was raising an exception when
29
+ passed out-of-bounds values for the row or column index (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=2660&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
30
+ Bug #2660</a>). This could happen, for example, if you were to
31
+ click in a table area outside of the regular cells (which indirectly
32
+ triggers a call to <tt class="methodname">makePositionVisible</tt>). This
33
+ was actually inconsistent with standard FOX behavior, which simply
34
+ ignores out of bounds values for that method's arguments. This bug has
35
+ been fixed, and the documentation for
36
+ <tt class="methodname">makePositionVisible</tt> has been updated
37
+ accordingly. Thanks to Ralf Jonas for reporting this problem.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.4.21 and
38
+ FXScintilla version 1.63.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2488"></a>Changes For Version 1.4.2 (August 22, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>Due to a bug in the implementation, the
4
39
  <tt class="methodname">checked?</tt> method for the
5
40
  <tt class="classname">FXCheckButton</tt> class always returned
6
41
  <tt class="constant">false</tt> (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=1852&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
@@ -26,8 +61,8 @@
26
61
  <span class="type">FXlong</span> type were defined, some methods for the
27
62
  <tt class="classname">FXFileStream</tt> class were broken (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=2275&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
28
63
  Bug #2275</a>). This problem has been corrected. Thanks to Gonzalo
29
- Garramuno for reporting this problem. </p></li><li style="list-style-type: disc"><p>Merged in all of the fixes for FXRuby 1.2.6.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.4.17 and
30
- FXScintilla version 1.63.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2494"></a>Changes For Version 1.4.1 (August 20, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>This is the second release of FXRuby which is compatible with
64
+ Garramuno for reporting this problem.</p></li><li style="list-style-type: disc"><p>Merged in all of the fixes for FXRuby 1.2.6.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.4.17 and
65
+ FXScintilla version 1.63.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2579"></a>Changes For Version 1.4.1 (August 20, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>This is the second release of FXRuby which is compatible with
31
66
  FOX 1.4, and as such should be considered an "unstable" release. For a
32
67
  history of the changes made during the FOX 1.3 and 1.4 development,
33
68
  see the <a href="http://www.fox-toolkit.com/news.html" target="_top">News</a>
@@ -36,11 +71,11 @@
36
71
  feature, and were still looking at <tt class="constant">fox12</tt>. This
37
72
  has been corrected.</p></li><li style="list-style-type: disc"><p>A number of minor problems were corrected for the Windows build
38
73
  of FXRuby.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.4.17 and
39
- FXScintilla version 1.63.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2522"></a>Changes For Version 1.4.0 (August 19, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>This is the first release of FXRuby which is compatible with FOX
74
+ FXScintilla version 1.63.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2607"></a>Changes For Version 1.4.0 (August 19, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>This is the first release of FXRuby which is compatible with FOX
40
75
  1.4, and as such should be considered an "unstable" release. For a
41
76
  history of the changes made during the FOX 1.3 and 1.4 development,
42
77
  see the <a href="http://www.fox-toolkit.com/news.html" target="_top">News</a>
43
- page at the FOX Web site.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2532"></a>Changes For Version 1.2.6 (April 15, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>Some additional problems related to calling the
78
+ page at the FOX Web site.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2617"></a>Changes For Version 1.2.6 (April 15, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>Some additional problems related to calling the
44
79
  <tt class="methodname">setTableSize</tt> method for an
45
80
  <tt class="classname">FXTable</tt> were discovered (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=1597&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
46
81
  Bug #1597</a>). This problem has been corrected. Thanks to Joel
@@ -88,7 +123,7 @@
88
123
  to be unavailable as well (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=1771&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
89
124
  Bug #1771</a>). This error has been corrected. Thanks to Jannis
90
125
  Pohlmann for reporting this problem.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.2.16 and
91
- FXScintilla version 1.62.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2668"></a>Changes For Version 1.2.5 (March 1, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>The change made for FXRuby version 1.2.4 regarding garbage
126
+ FXScintilla version 1.62.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2753"></a>Changes For Version 1.2.5 (March 1, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>The change made for FXRuby version 1.2.4 regarding garbage
92
127
  collection for table items corrected only one of the problems
93
128
  described in <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=1445&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
94
129
  Bug #1445</a>; There was still a problem related to the
@@ -118,7 +153,7 @@
118
153
  <tt class="methodname">selectRange</tt> method under the hood (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=1562&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
119
154
  Bug #1562</a>). Thanks to Joel VanderWerf for this
120
155
  suggestion.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.2.13 and
121
- FXScintilla version 1.62.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2753"></a>Changes For Version 1.2.4 (February 23, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>Due to a change in some of the internal Ruby C APIs, a
156
+ FXScintilla version 1.62.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2838"></a>Changes For Version 1.2.4 (February 23, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>Due to a change in some of the internal Ruby C APIs, a
122
157
  compile-time error for FXRuby was introduced in some of the Ruby 1.8.2
123
158
  preview releases (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=1039&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
124
159
  Bug #1039</a>). One should not see any compile-time errors when
@@ -168,7 +203,7 @@
168
203
  <tt class="classname">FXTable</tt> class (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=1426&amp;group_id=300&amp;atid=1226" target="_top">RubyForge
169
204
  Feature Request #1295</a>). Thanks to Brett Hallett for this
170
205
  suggestion.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.2.13 and
171
- FXScintilla version 1.62.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2856"></a>Changes For Version 1.2.3 (January 22, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>Since group boxes containing radio buttons no longer enforce the
206
+ FXScintilla version 1.62.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e2941"></a>Changes For Version 1.2.3 (January 22, 2005)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>Since group boxes containing radio buttons no longer enforce the
172
207
  radio behavior of radio buttons (i.e. keeping only one radio button
173
208
  selected at a time), some of the example programs were no longer
174
209
  working as desired (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=751&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
@@ -231,7 +266,7 @@
231
266
  documented incorrectly (see <a href="http://rubyforge.org/tracker/index.php?func=detail&amp;aid=1325&amp;group_id=300&amp;atid=1223" target="_top">RubyForge
232
267
  Bug #1325</a>). These have been corrected. Thanks to Karl El-Koura
233
268
  for reporting this problem.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.2.13 and
234
- FXScintilla version 1.62.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3028"></a>Changes For Version 1.2.2 (October 1, 2004)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>In order to avoid versioning problems when dealing with a mix of
269
+ FXScintilla version 1.62.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3113"></a>Changes For Version 1.2.2 (October 1, 2004)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>In order to avoid versioning problems when dealing with a mix of
235
270
  applications based on either FXRuby 1.0 or 1.2, the feature name for
236
271
  FXRuby has been changed from "fox" to "fox12". For most application
237
272
  developers, this means that you will need to modify the source code
@@ -239,7 +274,7 @@
239
274
  changes should be required for legacy applications targeted at FXRuby
240
275
  1.0.</p></li><li style="list-style-type: disc"><p>Made a number of updates to the documentation, to reflect API
241
276
  changes for FXRuby 1.2.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.2.9 and
242
- FXScintilla version 1.61.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3045"></a>Changes For Version 1.2a2 (July 10, 2004)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>This is the second "alpha" release of FXRuby 1.2. This release
277
+ FXScintilla version 1.61.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3130"></a>Changes For Version 1.2a2 (July 10, 2004)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>This is the second "alpha" release of FXRuby 1.2. This release
243
278
  should be compatible with any FOX library version 1.2; it is not
244
279
  compatible with any previous FOX library versions. As this is an alpha
245
280
  release, users should expect a certain amount of instability, bugs,
@@ -281,7 +316,7 @@
281
316
  or JPEG image support built-in (see <a href="http://sourceforge.net/tracker/index.php?func=detail&amp;aid=986180&amp;group_id=20243&amp;atid=120243" target="_top">SourceForge
282
317
  Bug #986180</a>). This has been fixed. Thanks to Bil Bas for
283
318
  reporting this problem.</p></li><li style="list-style-type: disc"><p>The binary gem for Windows was built with FOX version 1.2.7 and
284
- FXScintilla version 1.61.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3154"></a>Changes For Version 1.2a1 (June 28, 2004)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>This is the first "alpha" release of FXRuby 1.2. This release
319
+ FXScintilla version 1.61.</p></li></ul></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3239"></a>Changes For Version 1.2a1 (June 28, 2004)</h2></div></div><div></div></div><div class="itemizedlist"><ul type="bullet"><li style="list-style-type: disc"><p>This is the first "alpha" release of FXRuby 1.2. This release
285
320
  should be compatible with any FOX library version 1.2; it is not
286
321
  compatible with any previous FOX library versions. As this is an alpha
287
322
  release, users should expect a certain amount of instability, bugs,
data/doc/cvs.html CHANGED
@@ -19,13 +19,13 @@
19
19
  modified SWIG interface files. I always use the latest development version
20
20
  of <a href="http://www.swig.org" target="_top">SWIG</a>, but any release after,
21
21
  say, SWIG 1.3.15 should work fine. The older SWIG 1.1 releases will
22
- definitely <span class="emphasis"><em>not</em></span> work.</p><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4368"></a>Checking out the stable version</h2></div></div><div></div></div><p>The stable version of FXRuby is the 1.0.x branch and is compatible
22
+ definitely <span class="emphasis"><em>not</em></span> work.</p><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4453"></a>Checking out the stable version</h2></div></div><div></div></div><p>The stable version of FXRuby is the 1.0.x branch and is compatible
23
23
  with any of the FOX 1.0.x releases. It is <span class="emphasis"><em>not</em></span>
24
24
  compatible with any other release branches of FOX (e.g. the FOX 1.2.x or
25
25
  1.3.x series of releases).</p><p>To check out the stable version of FXRuby, do the following:</p><div class="orderedlist"><ol type="1"><li><p>Log in to the CVS server by typing:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="screen">cvs -d:pserver:anonymous@rubyforge.org:/var/cvs/fxruby login</pre></td></tr></table><p>When prompted for a password for <span class="emphasis"><em>anonymous</em></span>,
26
26
  simply press the <b class="keycap">Enter</b> key.</p></li><li><p>Check out the stable branch of FXRuby by typing:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="screen">cvs -z3 -d:pserver:anonymous@rubyforge.org:/var/cvs/fxruby co -rrelease10 FXRuby</pre></td></tr></table></li></ol></div><p>At this point, you should be ready to change to the top-level
27
27
  directory and go through the normal build and installation process, as
28
- described in an earlier chapter.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4401"></a>Regenerating wrapper code with SWIG</h2></div></div><div></div></div><p>If you make changes to any of the SWIG interface files (the files
28
+ described in an earlier chapter.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4486"></a>Regenerating wrapper code with SWIG</h2></div></div><div></div></div><p>If you make changes to any of the SWIG interface files (the files
29
29
  ending with a <tt class="filename">.i</tt> extension, in the <tt class="filename">swig-interfaces</tt> subdirectory) you will need
30
30
  to re-run SWIG to regenerate parts of the FXRuby source code:</p><div class="orderedlist"><ol type="1"><li><p>Change directories to the <tt class="filename">swig-interfaces</tt> subdirectory of the
31
31
  FXRuby source tree.</p></li><li><p>Type the following command to create a "bootstrap"
data/doc/differences.html CHANGED
@@ -1,11 +1,11 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"><link rel="previous" href="scintilla.html" title="Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby"><link rel="next" href="library.html" title="Appendix&nbsp;D.&nbsp;The FXRuby Standard Library"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="scintilla.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;II.&nbsp;Appendices</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="library.html">Next</a></td></tr></table><hr></div><div class="appendix" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="differences"></a>Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby</h2></div></div><div></div></div><p>The FXRuby API follows the FOX API very closely and for the most part, you should be able to use the standard FOX class documentation as a reference. In some cases, however, fundamental differences between Ruby and C++ necessitated slight changes in the API. For some other cases, FOX classes were enhanced to take advantage of Ruby language features (such as iterators). The purpose of this chapter is to identify some of the differences between the C++ and Ruby interfaces to FOX.</p><p>One difference that should be easy to cope with is the substitution of Ruby Strings for FXStrings. Any function that would normally expect an <span class="type">FXString</span> input argument insteads takes a Ruby String. Similarly, functions that would return an <span class="type">FXString</span> will instead return a Ruby string. For functions that would normally accept a <tt class="constant">NULL</tt> or empty string argument, just pass <tt class="constant">nil</tt> or an empty string ("").</p><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3449"></a>Functions that expect arrays of objects</h2></div></div><div></div></div><p>One common pattern in FOX member function argument lists is to expect a pointer to an array of values, followed by an integer indicating the number of values in the array. This of course isn't necessary in Ruby, where <tt class="classname">Array</tt> objects "know" their lengths. As a result, functions such as <tt class="methodname">FXWindow::acquireClipboard()</tt>, whose C++ declaration looks like this:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">FXbool acquireClipboard(const FXDragType *types, FXuint numTypes);</pre></td></tr></table><p>are called from Ruby code by passing in a single <tt class="classname">Array</tt> argument, e.g.</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">myWindow.acquireClipboard(typesArray)</pre></td></tr></table></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3469"></a>Functions that return values by reference</h2></div></div><div></div></div><p>Many FOX methods take advantage of the C++ language feature of returning values by reference. For example, the <tt class="methodname">getCursorPos()</tt> member function for class <tt class="classname">FXWindow</tt> has the declaration:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">FXint getCursorPos(FXint&amp; x, FXint&amp; y, FXint&amp; buttons) const;</pre></td></tr></table><p>which indicates that the function takes references to three integers (x, y and buttons). To call this function from a C++ program, you'd write code like this:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">FXint x, y;
3
+ <title>Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"><link rel="previous" href="scintilla.html" title="Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby"><link rel="next" href="library.html" title="Appendix&nbsp;D.&nbsp;The FXRuby Standard Library"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="scintilla.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;II.&nbsp;Appendices</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="library.html">Next</a></td></tr></table><hr></div><div class="appendix" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="differences"></a>Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby</h2></div></div><div></div></div><p>The FXRuby API follows the FOX API very closely and for the most part, you should be able to use the standard FOX class documentation as a reference. In some cases, however, fundamental differences between Ruby and C++ necessitated slight changes in the API. For some other cases, FOX classes were enhanced to take advantage of Ruby language features (such as iterators). The purpose of this chapter is to identify some of the differences between the C++ and Ruby interfaces to FOX.</p><p>One difference that should be easy to cope with is the substitution of Ruby Strings for FXStrings. Any function that would normally expect an <span class="type">FXString</span> input argument insteads takes a Ruby String. Similarly, functions that would return an <span class="type">FXString</span> will instead return a Ruby string. For functions that would normally accept a <tt class="constant">NULL</tt> or empty string argument, just pass <tt class="constant">nil</tt> or an empty string ("").</p><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3534"></a>Functions that expect arrays of objects</h2></div></div><div></div></div><p>One common pattern in FOX member function argument lists is to expect a pointer to an array of values, followed by an integer indicating the number of values in the array. This of course isn't necessary in Ruby, where <tt class="classname">Array</tt> objects "know" their lengths. As a result, functions such as <tt class="methodname">FXWindow::acquireClipboard()</tt>, whose C++ declaration looks like this:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">FXbool acquireClipboard(const FXDragType *types, FXuint numTypes);</pre></td></tr></table><p>are called from Ruby code by passing in a single <tt class="classname">Array</tt> argument, e.g.</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">myWindow.acquireClipboard(typesArray)</pre></td></tr></table></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3554"></a>Functions that return values by reference</h2></div></div><div></div></div><p>Many FOX methods take advantage of the C++ language feature of returning values by reference. For example, the <tt class="methodname">getCursorPos()</tt> member function for class <tt class="classname">FXWindow</tt> has the declaration:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">FXint getCursorPos(FXint&amp; x, FXint&amp; y, FXint&amp; buttons) const;</pre></td></tr></table><p>which indicates that the function takes references to three integers (x, y and buttons). To call this function from a C++ program, you'd write code like this:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">FXint x, y;
4
4
  FXuint buttons;
5
5
 
6
6
  if (window-&gt;getCursorPosition(x, y, buttons))
7
- fprintf(stderr, "Current position is (%d, %d)\n", x, y);</pre></td></tr></table><p>Since this idiom doesn't translate well to Ruby, some functions' interfaces have been slightly modified. For example, the FXRuby implementation of <tt class="methodname">getCursorPos()</tt> returns the three values as an <tt class="classname">Array</tt>, e.g.:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">x, y, buttons = aWindow.getCursorPos()</pre></td></tr></table><p>The following table shows how these kinds of functions are implemented in FXRuby:</p><div class="informaltable"><table border="1"><colgroup><col><col></colgroup><thead><tr><th align="center">Instance Method</th><th align="center">Return Value</th></tr></thead><tbody><tr><td><tt class="methodname">FXDial#range</tt></td><td>Returns a <tt class="classname">Range</tt> instance.</td></tr><tr><td><tt class="methodname">FXDial#range=(aRange)</tt></td><td>Accepts a <tt class="classname">Range</tt> instance as its input.</td></tr><tr><td><tt class="methodname">FXFontDialog#fontSelection</tt></td><td>Returns the <tt class="classname">FXFontDesc</tt> instance</td></tr><tr><td><tt class="methodname">FXFontSelector#fontSelection</tt></td><td>Returns the <tt class="classname">FXFontDesc</tt> instance</td></tr><tr><td><tt class="methodname">FXGLObject#bounds(range)</tt></td><td>Takes an <tt class="classname">FXRange</tt> instance as its input and returns a (possibly modified) <tt class="classname">FXRange</tt> instance.</td></tr><tr><td><tt class="methodname">FXGLViewer#eyeToScreen(eye)</tt></td><td>Takes an array of eye coordinates (floats) as its input and returns the screen point coordinate as an array of integers [sx, sy]</td></tr><tr><td><tt class="methodname">FXGLViewer#getBoreVector(sx, sy)</tt></td><td>Returns the endpoint and direction vector as an array of arrays [point, dir]</td></tr><tr><td><tt class="methodname">FXGLViewer#light</tt></td><td>Returns a <tt class="classname">FXLight</tt> instance</td></tr><tr><td><tt class="methodname">FXGLViewer#viewport</tt></td><td>Returns an <tt class="classname">FXViewport</tt> instance.</td></tr><tr><td><tt class="methodname">FXPrinterDialog#printer</tt></td><td>Returns the <tt class="classname">FXPrinter</tt> instance</td></tr><tr><td><tt class="methodname">FXScrollArea#position</tt></td><td>Returns the position as an array of integers [x, y]</td></tr><tr><td><tt class="methodname">FXSlider#range</tt></td><td>Returns a <tt class="classname">Range</tt> instance.</td></tr><tr><td><tt class="methodname">FXSlider#range=(aRange)</tt></td><td>Accepts a <tt class="classname">Range</tt> instance as its input.</td></tr><tr><td><tt class="methodname">FXSpinner#range</tt></td><td>Returns a <tt class="classname">Range</tt> instance.</td></tr><tr><td><tt class="methodname">FXSpinner#range=(aRange)</tt></td><td>Accepts a <tt class="classname">Range</tt> instance as its input.</td></tr><tr><td><tt class="methodname">FXText#appendText(text, notify=false)</tt></td><td>Append text to the end of the buffer.</td></tr><tr><td><tt class="methodname">FXText#appendStyledText(text, style=0, notify=false)</tt></td><td>Append styled text to the end of the buffer.</td></tr><tr><td><tt class="methodname">FXText#extractText(pos, n)</tt></td><td>Extracts <span class="emphasis"><em>n</em></span> characters from the buffer beginning at position <span class="emphasis"><em>pos</em></span> and returns the result as a String.</td></tr><tr><td><tt class="methodname">FXText#extractStyle(pos, n)</tt></td><td>Extracts <span class="emphasis"><em>n</em></span> style characters from the buffer beginning at position <span class="emphasis"><em>pos</em></span> and returns the result as a String.</td></tr><tr><td><tt class="methodname">FXText#insertText(pos, text, notify=false)</tt></td><td>Insert <span class="emphasis"><em>text</em></span> at position <span class="emphasis"><em>pos</em></span> in the buffer.</td></tr><tr><td><tt class="methodname">FXText#insertStyledText(pos, text, style=0, notify=false)</tt></td><td>Insert <span class="emphasis"><em>text</em></span> at position <span class="emphasis"><em>pos</em></span> in the buffer.</td></tr><tr><td><tt class="methodname">FXText#replaceText(pos, m, text, notify=false)</tt></td><td>Replace <span class="emphasis"><em>m</em></span> characters at <span class="emphasis"><em>pos</em></span> by <span class="emphasis"><em>text</em></span>.</td></tr><tr><td><tt class="methodname">FXText#replaceStyledText(pos, m, text, style=0, notify=false)</tt></td><td>Replace <span class="emphasis"><em>m</em></span> characters at <span class="emphasis"><em>pos</em></span> by <span class="emphasis"><em>text</em></span>.</td></tr><tr><td><tt class="methodname">FXText#setDelimiters(delimiters)</tt></td><td>Change delimiters of words (<span class="emphasis"><em>delimiters</em></span> is a string).</td></tr><tr><td><tt class="methodname">FXText#getDelimiters()</tt></td><td>Return word delimiters as a string.</td></tr><tr><td><tt class="methodname">FXWindow#cursorPosition</tt></td><td>Returns an array of integers [x, y, buttons]</td></tr><tr><td><tt class="methodname">FXWindow#translateCoordinatesFrom(window, x, y)</tt></td><td>Returns the translated coordinates as an array [x, y]</td></tr><tr><td><tt class="methodname">FXWindow#translateCoordinatesTo(window, x, y)</tt></td><td>Returns the translated coordinates as an array [x, y]</td></tr></tbody></table></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3759"></a>Iterators</h2></div></div><div></div></div><p>Several classes have been extended with an <tt class="methodname">each</tt> method to provide Ruby-style iterators. These classes include <tt class="classname">FXComboBox</tt>, <tt class="classname">FXGLGroup</tt>, <tt class="classname">FXHeader</tt>, <tt class="classname">FXIconList</tt>, <tt class="classname">FXList</tt>, <tt class="classname">FXListBox</tt>, <tt class="classname">FXTreeItem</tt>, <tt class="classname">FXTreeList</tt> and <tt class="classname">FXTreeListBox</tt>. These classes also mix-in Ruby's <tt class="classname">Enumerable</tt> module so that you can take full advantage of the iterators.</p><p>The block parameters passed to your code block vary depending on the class. For example, iterating over an <tt class="classname">FXList</tt> instance yields <tt class="classname">FXListItem</tt> parameters:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">aList.each { |aListItem|
7
+ fprintf(stderr, "Current position is (%d, %d)\n", x, y);</pre></td></tr></table><p>Since this idiom doesn't translate well to Ruby, some functions' interfaces have been slightly modified. For example, the FXRuby implementation of <tt class="methodname">getCursorPos()</tt> returns the three values as an <tt class="classname">Array</tt>, e.g.:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">x, y, buttons = aWindow.getCursorPos()</pre></td></tr></table><p>The following table shows how these kinds of functions are implemented in FXRuby:</p><div class="informaltable"><table border="1"><colgroup><col><col></colgroup><thead><tr><th align="center">Instance Method</th><th align="center">Return Value</th></tr></thead><tbody><tr><td><tt class="methodname">FXDial#range</tt></td><td>Returns a <tt class="classname">Range</tt> instance.</td></tr><tr><td><tt class="methodname">FXDial#range=(aRange)</tt></td><td>Accepts a <tt class="classname">Range</tt> instance as its input.</td></tr><tr><td><tt class="methodname">FXFontDialog#fontSelection</tt></td><td>Returns the <tt class="classname">FXFontDesc</tt> instance</td></tr><tr><td><tt class="methodname">FXFontSelector#fontSelection</tt></td><td>Returns the <tt class="classname">FXFontDesc</tt> instance</td></tr><tr><td><tt class="methodname">FXGLObject#bounds(range)</tt></td><td>Takes an <tt class="classname">FXRange</tt> instance as its input and returns a (possibly modified) <tt class="classname">FXRange</tt> instance.</td></tr><tr><td><tt class="methodname">FXGLViewer#eyeToScreen(eye)</tt></td><td>Takes an array of eye coordinates (floats) as its input and returns the screen point coordinate as an array of integers [sx, sy]</td></tr><tr><td><tt class="methodname">FXGLViewer#getBoreVector(sx, sy)</tt></td><td>Returns the endpoint and direction vector as an array of arrays [point, dir]</td></tr><tr><td><tt class="methodname">FXGLViewer#light</tt></td><td>Returns a <tt class="classname">FXLight</tt> instance</td></tr><tr><td><tt class="methodname">FXGLViewer#viewport</tt></td><td>Returns an <tt class="classname">FXViewport</tt> instance.</td></tr><tr><td><tt class="methodname">FXPrinterDialog#printer</tt></td><td>Returns the <tt class="classname">FXPrinter</tt> instance</td></tr><tr><td><tt class="methodname">FXScrollArea#position</tt></td><td>Returns the position as an array of integers [x, y]</td></tr><tr><td><tt class="methodname">FXSlider#range</tt></td><td>Returns a <tt class="classname">Range</tt> instance.</td></tr><tr><td><tt class="methodname">FXSlider#range=(aRange)</tt></td><td>Accepts a <tt class="classname">Range</tt> instance as its input.</td></tr><tr><td><tt class="methodname">FXSpinner#range</tt></td><td>Returns a <tt class="classname">Range</tt> instance.</td></tr><tr><td><tt class="methodname">FXSpinner#range=(aRange)</tt></td><td>Accepts a <tt class="classname">Range</tt> instance as its input.</td></tr><tr><td><tt class="methodname">FXText#appendText(text, notify=false)</tt></td><td>Append text to the end of the buffer.</td></tr><tr><td><tt class="methodname">FXText#appendStyledText(text, style=0, notify=false)</tt></td><td>Append styled text to the end of the buffer.</td></tr><tr><td><tt class="methodname">FXText#extractText(pos, n)</tt></td><td>Extracts <span class="emphasis"><em>n</em></span> characters from the buffer beginning at position <span class="emphasis"><em>pos</em></span> and returns the result as a String.</td></tr><tr><td><tt class="methodname">FXText#extractStyle(pos, n)</tt></td><td>Extracts <span class="emphasis"><em>n</em></span> style characters from the buffer beginning at position <span class="emphasis"><em>pos</em></span> and returns the result as a String.</td></tr><tr><td><tt class="methodname">FXText#insertText(pos, text, notify=false)</tt></td><td>Insert <span class="emphasis"><em>text</em></span> at position <span class="emphasis"><em>pos</em></span> in the buffer.</td></tr><tr><td><tt class="methodname">FXText#insertStyledText(pos, text, style=0, notify=false)</tt></td><td>Insert <span class="emphasis"><em>text</em></span> at position <span class="emphasis"><em>pos</em></span> in the buffer.</td></tr><tr><td><tt class="methodname">FXText#replaceText(pos, m, text, notify=false)</tt></td><td>Replace <span class="emphasis"><em>m</em></span> characters at <span class="emphasis"><em>pos</em></span> by <span class="emphasis"><em>text</em></span>.</td></tr><tr><td><tt class="methodname">FXText#replaceStyledText(pos, m, text, style=0, notify=false)</tt></td><td>Replace <span class="emphasis"><em>m</em></span> characters at <span class="emphasis"><em>pos</em></span> by <span class="emphasis"><em>text</em></span>.</td></tr><tr><td><tt class="methodname">FXText#setDelimiters(delimiters)</tt></td><td>Change delimiters of words (<span class="emphasis"><em>delimiters</em></span> is a string).</td></tr><tr><td><tt class="methodname">FXText#getDelimiters()</tt></td><td>Return word delimiters as a string.</td></tr><tr><td><tt class="methodname">FXWindow#cursorPosition</tt></td><td>Returns an array of integers [x, y, buttons]</td></tr><tr><td><tt class="methodname">FXWindow#translateCoordinatesFrom(window, x, y)</tt></td><td>Returns the translated coordinates as an array [x, y]</td></tr><tr><td><tt class="methodname">FXWindow#translateCoordinatesTo(window, x, y)</tt></td><td>Returns the translated coordinates as an array [x, y]</td></tr></tbody></table></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3844"></a>Iterators</h2></div></div><div></div></div><p>Several classes have been extended with an <tt class="methodname">each</tt> method to provide Ruby-style iterators. These classes include <tt class="classname">FXComboBox</tt>, <tt class="classname">FXGLGroup</tt>, <tt class="classname">FXHeader</tt>, <tt class="classname">FXIconList</tt>, <tt class="classname">FXList</tt>, <tt class="classname">FXListBox</tt>, <tt class="classname">FXTreeItem</tt>, <tt class="classname">FXTreeList</tt> and <tt class="classname">FXTreeListBox</tt>. These classes also mix-in Ruby's <tt class="classname">Enumerable</tt> module so that you can take full advantage of the iterators.</p><p>The block parameters passed to your code block vary depending on the class. For example, iterating over an <tt class="classname">FXList</tt> instance yields <tt class="classname">FXListItem</tt> parameters:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">aList.each { |aListItem|
8
8
  puts "text for this item = #{aListItem.getText()}"
9
9
  }</pre></td></tr></table><p>whereas iterating over an <tt class="classname">FXComboBox</tt> instance yields two parameters, the item text (a string) and the item data:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">aComboBox.each { |itemText, itemData|
10
10
  puts "text for this item = #{itemText}"
11
- }</pre></td></tr></table><p>The following table shows the block parameters for each of these classes' iterators:</p><div class="informaltable"><table border="1"><colgroup><col><col></colgroup><thead><tr><th align="center">Class</th><th align="center">Block Parameters</th></tr></thead><tbody><tr><td><tt class="classname">FXComboBox</tt></td><td>the item text (a string) and user data</td></tr><tr><td><tt class="classname">FXGLGroup</tt></td><td>an <tt class="classname">FXGLObject</tt> instance</td></tr><tr><td><tt class="classname">FXHeader</tt></td><td>an <tt class="classname">FXHeaderItem</tt> instance</td></tr><tr><td><tt class="classname">FXIconList</tt></td><td>an <tt class="classname">FXIconItem</tt> instance</td></tr><tr><td><tt class="classname">FXList</tt></td><td>an <tt class="classname">FXListItem</tt> instance</td></tr><tr><td><tt class="classname">FXListBox</tt></td><td>the item text (a string), icon (an <tt class="classname">FXIcon</tt> instance) and user data</td></tr><tr><td><tt class="classname">FXTreeItem</tt></td><td>an <tt class="classname">FXTreeItem</tt> instance</td></tr><tr><td><tt class="classname">FXTreeList</tt></td><td>an <tt class="classname">FXTreeItem</tt> instance</td></tr><tr><td><tt class="classname">FXTreeListBox</tt></td><td>an <tt class="classname">FXTreeItem</tt> instance</td></tr></tbody></table></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3903"></a>Attribute Accessors</h2></div></div><div></div></div><p>FOX strictly handles access to all object attributes through member functions, e.g. <tt class="methodname">setBackgroundColor</tt> and <tt class="methodname">getBackgroundColor</tt> or <tt class="methodname">setText</tt> and <tt class="methodname">getText</tt>. FXRuby exposes all of these functions but also provides aliases that look more like regular Ruby attribute accessors. The names for these accessors are based on the FOX method names; for example, <tt class="methodname">setBackgroundColor</tt> and <tt class="methodname">getBackgroundColor</tt> are aliased to <tt class="methodname">backgroundColor=</tt> and <tt class="methodname">backgroundColor</tt>, respectively.</p><p>In many cases these aliases allow you to write more compact and legible code. For example, consider this code snippet:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">aLabel.setText(aLabel.getText() + " (modified)")</pre></td></tr></table><p>Now consider a different code snippet, using the aliased accessor method names:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">aLabel.text += " (modified)"</pre></td></tr></table><p>While these two are functionally equivalent, the latter is a bit easier to read and understand at first glance.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3942"></a>Message Passing</h2></div></div><div></div></div><p>FOX message maps are implemented as static C++ class members. With FXRuby, you just associate messages with message handlers in the class <tt class="methodname">initialize</tt> method using the <tt class="methodname">FXMAPFUNC()</tt>, <tt class="methodname">FXMAPTYPE()</tt>, <tt class="methodname">FXMAPTYPES()</tt> or <tt class="methodname">FXMAPFUNCS()</tt> methods. See almost any of the example programs for examples of how this is done.</p><p>As in C++ FOX, the last argument passed to your message handler functions contains message-specific data. For instance, all <tt class="constant">SEL_PAINT</tt> messages pass an <tt class="classname">FXEvent</tt> object through this argument to give you some information about the size of the exposed rectangle. On the other hand, a <tt class="constant">SEL_COMMAND</tt> message from an <tt class="classname">FXHeader</tt> object passes the index of the selected header item through this argument. Instead of guessing what's in this last argument, your best bet is to instead invoke a member function on the sending object to find out what you need, instead of relying on the data passed through this pointer. For example, if you get a <tt class="constant">SEL_COMMAND</tt> message from an <tt class="classname">FXColorWell</tt> object, the data passed through that last argument is supposed to be the new RGB color value. Instead of trying to interpret the argument's contents, just turn around and call the color well's <tt class="methodname">getRGBA()</tt> member function to retrieve its color. Similarly, if you get a <tt class="constant">SEL_COMMAND</tt> message from a tree list, call its <tt class="methodname">getCurrentItem()</tt> method to find out which item was selected.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3991"></a>Catching Operating System Signals</h2></div></div><div></div></div><p>The <tt class="methodname">FXApp#addSignal</tt> and <tt class="methodname">FXApp#removeSignal</tt> methods have been enhanced to accept either a string or integer as their first argument. If it's a string (e.g. "SIGINT" or just "INT") the code will determine the corresponding signal number for you (similar to the standard Ruby library's <tt class="methodname">Process.kill</tt> module method). For examples of how to use this, see the <tt class="filename">datatarget.rb</tt> or <tt class="filename">imageviewer.rb</tt> example programs.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4011"></a>Support for Multithreaded Applications</h2></div></div><div></div></div><p>There is some support for multithreaded FXRuby applications, but it's not wonderful. The current implementation does what is also done in Ruby/GTK; it turns over some idle processing time to the Ruby thread scheduler to let other threads do their thing. As I learn more about Ruby's threading implementation I may try something different, but this seems to work OK for now. For a simple example, see the <tt class="filename">groupbox.rb</tt> example program, in which the clock label that appears in the lower right-hand corner is continuously updated (by a separate thread).</p><p>If you suspect that FXRuby's threads support is interfering with your application's performance, you may want to try tweaking the amount of time that the main application thread "sleeps" during idle processing; do this by setting the <tt class="classname">FXApp</tt> object's <i class="structfield"><tt>sleepTime</tt></i> attribute. The default value for <i class="structfield"><tt>FXApp#sleepTime</tt></i> is 100 milliseconds. You can also disable the threads support completely by calling <tt class="methodname">FXApp#threadsEnabled=false</tt> (and subsequently re-enable it with <tt class="methodname">FXApp#threadsEnabled=true</tt>).</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4036"></a>Debugging Tricks</h2></div></div><div></div></div><p>As a debugging tool, you can optionally catch exceptions raised in message handlers. To turn on this feature, call the <tt class="methodname">setIgnoreExceptions(true)</tt> module method. When this is enabled, any exceptions raised in message handler functions will cause a standard stack trace to be dumped to the standard output, but then your application will, for better or worse, proceed normally. Thanks to Ted Meng for this suggestion.</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="scintilla.html">Prev</a>&nbsp;</td><td width="20%" align="center"><a accesskey="u" href="pt02.html">Up</a></td><td width="40%" align="right">&nbsp;<a accesskey="n" href="library.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby&nbsp;</td><td width="20%" align="center"><a accesskey="h" href="book.html">Home</a></td><td width="40%" align="right" valign="top">&nbsp;Appendix&nbsp;D.&nbsp;The FXRuby Standard Library</td></tr></table></div></body></html>
11
+ }</pre></td></tr></table><p>The following table shows the block parameters for each of these classes' iterators:</p><div class="informaltable"><table border="1"><colgroup><col><col></colgroup><thead><tr><th align="center">Class</th><th align="center">Block Parameters</th></tr></thead><tbody><tr><td><tt class="classname">FXComboBox</tt></td><td>the item text (a string) and user data</td></tr><tr><td><tt class="classname">FXGLGroup</tt></td><td>an <tt class="classname">FXGLObject</tt> instance</td></tr><tr><td><tt class="classname">FXHeader</tt></td><td>an <tt class="classname">FXHeaderItem</tt> instance</td></tr><tr><td><tt class="classname">FXIconList</tt></td><td>an <tt class="classname">FXIconItem</tt> instance</td></tr><tr><td><tt class="classname">FXList</tt></td><td>an <tt class="classname">FXListItem</tt> instance</td></tr><tr><td><tt class="classname">FXListBox</tt></td><td>the item text (a string), icon (an <tt class="classname">FXIcon</tt> instance) and user data</td></tr><tr><td><tt class="classname">FXTreeItem</tt></td><td>an <tt class="classname">FXTreeItem</tt> instance</td></tr><tr><td><tt class="classname">FXTreeList</tt></td><td>an <tt class="classname">FXTreeItem</tt> instance</td></tr><tr><td><tt class="classname">FXTreeListBox</tt></td><td>an <tt class="classname">FXTreeItem</tt> instance</td></tr></tbody></table></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3988"></a>Attribute Accessors</h2></div></div><div></div></div><p>FOX strictly handles access to all object attributes through member functions, e.g. <tt class="methodname">setBackgroundColor</tt> and <tt class="methodname">getBackgroundColor</tt> or <tt class="methodname">setText</tt> and <tt class="methodname">getText</tt>. FXRuby exposes all of these functions but also provides aliases that look more like regular Ruby attribute accessors. The names for these accessors are based on the FOX method names; for example, <tt class="methodname">setBackgroundColor</tt> and <tt class="methodname">getBackgroundColor</tt> are aliased to <tt class="methodname">backgroundColor=</tt> and <tt class="methodname">backgroundColor</tt>, respectively.</p><p>In many cases these aliases allow you to write more compact and legible code. For example, consider this code snippet:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">aLabel.setText(aLabel.getText() + " (modified)")</pre></td></tr></table><p>Now consider a different code snippet, using the aliased accessor method names:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">aLabel.text += " (modified)"</pre></td></tr></table><p>While these two are functionally equivalent, the latter is a bit easier to read and understand at first glance.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4027"></a>Message Passing</h2></div></div><div></div></div><p>FOX message maps are implemented as static C++ class members. With FXRuby, you just associate messages with message handlers in the class <tt class="methodname">initialize</tt> method using the <tt class="methodname">FXMAPFUNC()</tt>, <tt class="methodname">FXMAPTYPE()</tt>, <tt class="methodname">FXMAPTYPES()</tt> or <tt class="methodname">FXMAPFUNCS()</tt> methods. See almost any of the example programs for examples of how this is done.</p><p>As in C++ FOX, the last argument passed to your message handler functions contains message-specific data. For instance, all <tt class="constant">SEL_PAINT</tt> messages pass an <tt class="classname">FXEvent</tt> object through this argument to give you some information about the size of the exposed rectangle. On the other hand, a <tt class="constant">SEL_COMMAND</tt> message from an <tt class="classname">FXHeader</tt> object passes the index of the selected header item through this argument. Instead of guessing what's in this last argument, your best bet is to instead invoke a member function on the sending object to find out what you need, instead of relying on the data passed through this pointer. For example, if you get a <tt class="constant">SEL_COMMAND</tt> message from an <tt class="classname">FXColorWell</tt> object, the data passed through that last argument is supposed to be the new RGB color value. Instead of trying to interpret the argument's contents, just turn around and call the color well's <tt class="methodname">getRGBA()</tt> member function to retrieve its color. Similarly, if you get a <tt class="constant">SEL_COMMAND</tt> message from a tree list, call its <tt class="methodname">getCurrentItem()</tt> method to find out which item was selected.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4076"></a>Catching Operating System Signals</h2></div></div><div></div></div><p>The <tt class="methodname">FXApp#addSignal</tt> and <tt class="methodname">FXApp#removeSignal</tt> methods have been enhanced to accept either a string or integer as their first argument. If it's a string (e.g. "SIGINT" or just "INT") the code will determine the corresponding signal number for you (similar to the standard Ruby library's <tt class="methodname">Process.kill</tt> module method). For examples of how to use this, see the <tt class="filename">datatarget.rb</tt> or <tt class="filename">imageviewer.rb</tt> example programs.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4096"></a>Support for Multithreaded Applications</h2></div></div><div></div></div><p>There is some support for multithreaded FXRuby applications, but it's not wonderful. The current implementation does what is also done in Ruby/GTK; it turns over some idle processing time to the Ruby thread scheduler to let other threads do their thing. As I learn more about Ruby's threading implementation I may try something different, but this seems to work OK for now. For a simple example, see the <tt class="filename">groupbox.rb</tt> example program, in which the clock label that appears in the lower right-hand corner is continuously updated (by a separate thread).</p><p>If you suspect that FXRuby's threads support is interfering with your application's performance, you may want to try tweaking the amount of time that the main application thread "sleeps" during idle processing; do this by setting the <tt class="classname">FXApp</tt> object's <i class="structfield"><tt>sleepTime</tt></i> attribute. The default value for <i class="structfield"><tt>FXApp#sleepTime</tt></i> is 100 milliseconds. You can also disable the threads support completely by calling <tt class="methodname">FXApp#threadsEnabled=false</tt> (and subsequently re-enable it with <tt class="methodname">FXApp#threadsEnabled=true</tt>).</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4121"></a>Debugging Tricks</h2></div></div><div></div></div><p>As a debugging tool, you can optionally catch exceptions raised in message handlers. To turn on this feature, call the <tt class="methodname">setIgnoreExceptions(true)</tt> module method. When this is enabled, any exceptions raised in message handler functions will cause a standard stack trace to be dumped to the standard output, but then your application will, for better or worse, proceed normally. Thanks to Ted Meng for this suggestion.</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="scintilla.html">Prev</a>&nbsp;</td><td width="20%" align="center"><a accesskey="u" href="pt02.html">Up</a></td><td width="40%" align="right">&nbsp;<a accesskey="n" href="library.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby&nbsp;</td><td width="20%" align="center"><a accesskey="h" href="book.html">Home</a></td><td width="40%" align="right" valign="top">&nbsp;Appendix&nbsp;D.&nbsp;The FXRuby Standard Library</td></tr></table></div></body></html>
@@ -1,6 +1,6 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Appendix&nbsp;E.&nbsp;Implementation</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"><link rel="previous" href="library.html" title="Appendix&nbsp;D.&nbsp;The FXRuby Standard Library"><link rel="next" href="apes02.html" title="Object Life Cycles and Garbage Collection"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Appendix&nbsp;E.&nbsp;Implementation</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="library.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;II.&nbsp;Appendices</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="apes02.html">Next</a></td></tr></table><hr></div><div class="appendix" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="implementation"></a>Appendix&nbsp;E.&nbsp;Implementation</h2></div></div><div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><a href="implementation.html#d0e4187">Code Generation</a></dt><dt><a href="apes02.html">Object Life Cycles and Garbage Collection</a></dt><dd><dl><dt><a href="apes02.html#d0e4225">GL Objects</a></dt></dl></dd><dt><a href="apes03.html">Virtual Functions</a></dt></dl></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4187"></a>Code Generation</h2></div></div><div></div></div><p>The development and maintenance of FXRuby would be almost impossible
3
+ <title>Appendix&nbsp;E.&nbsp;Implementation</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"><link rel="previous" href="library.html" title="Appendix&nbsp;D.&nbsp;The FXRuby Standard Library"><link rel="next" href="apes02.html" title="Object Life Cycles and Garbage Collection"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Appendix&nbsp;E.&nbsp;Implementation</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="library.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;II.&nbsp;Appendices</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="apes02.html">Next</a></td></tr></table><hr></div><div class="appendix" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="implementation"></a>Appendix&nbsp;E.&nbsp;Implementation</h2></div></div><div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><a href="implementation.html#d0e4272">Code Generation</a></dt><dt><a href="apes02.html">Object Life Cycles and Garbage Collection</a></dt><dd><dl><dt><a href="apes02.html#d0e4310">GL Objects</a></dt></dl></dd><dt><a href="apes03.html">Virtual Functions</a></dt></dl></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4272"></a>Code Generation</h2></div></div><div></div></div><p>The development and maintenance of FXRuby would be almost impossible
4
4
  without the help of Dave Beazley's excellent
5
5
  <a href="http://www.swig.org" target="_top">SWIG</a>. The complete set of SWIG
6
6
  interface files used to generate FXRuby is included in the standard
data/doc/library.html CHANGED
@@ -1,18 +1,18 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Appendix&nbsp;D.&nbsp;The FXRuby Standard Library</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"><link rel="previous" href="differences.html" title="Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby"><link rel="next" href="implementation.html" title="Appendix&nbsp;E.&nbsp;Implementation"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Appendix&nbsp;D.&nbsp;The FXRuby Standard Library</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="differences.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;II.&nbsp;Appendices</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="implementation.html">Next</a></td></tr></table><hr></div><div class="appendix" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="library"></a>Appendix&nbsp;D.&nbsp;The FXRuby Standard Library</h2></div></div><div></div></div><p>While the majority of FXRuby is in fact implemented by an extension module, some parts are provided instead by "pure Ruby" code. This section describes the classes and modules available in the FXRuby standard library.</p><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4049"></a>Undoable Commands</h2></div></div><div></div></div><p>The <tt class="filename">fox/undolist.rb</tt> file provides the <tt class="classname">FXCommand</tt> and <tt class="classname">FXUndoList</tt> classes. These serve the same purpose as the <tt class="classname">FXCommand</tt> and <tt class="classname">FXUndoList</tt> classes from the standard FOX distribution, but they're implemented entirely in Ruby.</p><p>For a complete description of these classes and how to use them, see the RD documentation in <tt class="filename">fox/undolist.rb</tt>.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4074"></a>Aliases</h2></div></div><div></div></div><p>The <tt class="filename">fox/aliases.rb</tt> implements most of the accessor-style aliases for methods. This file is loaded automatically when you </p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">require 'fox'</pre></td></tr></table><p> and so you should never need to load it directly.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4085"></a>Color Names</h2></div></div><div></div></div><p>The <tt class="filename">fox/colors.rb</tt> file, contributed by Jeff
3
+ <title>Appendix&nbsp;D.&nbsp;The FXRuby Standard Library</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"><link rel="previous" href="differences.html" title="Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby"><link rel="next" href="implementation.html" title="Appendix&nbsp;E.&nbsp;Implementation"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Appendix&nbsp;D.&nbsp;The FXRuby Standard Library</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="differences.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;II.&nbsp;Appendices</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="implementation.html">Next</a></td></tr></table><hr></div><div class="appendix" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="library"></a>Appendix&nbsp;D.&nbsp;The FXRuby Standard Library</h2></div></div><div></div></div><p>While the majority of FXRuby is in fact implemented by an extension module, some parts are provided instead by "pure Ruby" code. This section describes the classes and modules available in the FXRuby standard library.</p><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4134"></a>Undoable Commands</h2></div></div><div></div></div><p>The <tt class="filename">fox/undolist.rb</tt> file provides the <tt class="classname">FXCommand</tt> and <tt class="classname">FXUndoList</tt> classes. These serve the same purpose as the <tt class="classname">FXCommand</tt> and <tt class="classname">FXUndoList</tt> classes from the standard FOX distribution, but they're implemented entirely in Ruby.</p><p>For a complete description of these classes and how to use them, see the RD documentation in <tt class="filename">fox/undolist.rb</tt>.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4159"></a>Aliases</h2></div></div><div></div></div><p>The <tt class="filename">fox/aliases.rb</tt> implements most of the accessor-style aliases for methods. This file is loaded automatically when you </p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">require 'fox'</pre></td></tr></table><p> and so you should never need to load it directly.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4170"></a>Color Names</h2></div></div><div></div></div><p>The <tt class="filename">fox/colors.rb</tt> file, contributed by Jeff
4
4
  Heard, provides a bunch of predefined color values (based on the standard
5
5
  X11 color names). You can use these color constants anywhere that FOX
6
6
  expects an RGB color value, e.g.</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">dc = FXDCWindow.new(drawable, ev)
7
7
  dc.foreground = FXColor::MistyRose # instead of FXRGB(255, 228, 225)
8
- dc.background = FXColor::MidnightBlue # instead of FXRGB( 25, 25, 112)</pre></td></tr></table></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4095"></a>OpenGL Shapes</h2></div></div><div></div></div><p>The <tt class="filename">fox/glshapes.rb</tt> library provides Ruby
8
+ dc.background = FXColor::MidnightBlue # instead of FXRGB( 25, 25, 112)</pre></td></tr></table></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4180"></a>OpenGL Shapes</h2></div></div><div></div></div><p>The <tt class="filename">fox/glshapes.rb</tt> library provides Ruby
9
9
  implementations of a number of basic 3-D shapes (all derived from the
10
10
  built-in <tt class="classname">FXGLShape</tt> class) that can be used with
11
11
  the <tt class="classname">FXGLViewer</tt>. Several of these shapes are used
12
12
  in the <tt class="filename">glviewer.rb</tt> example program. These shapes
13
13
  were originally implemented in C++ and wrapped using SWIG, but they are
14
14
  straightforward enough to implement in Ruby so they were moved out to
15
- this library instead.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4112"></a>Iterators</h2></div></div><div></div></div><p>The <tt class="filename">fox/iterators.rb</tt> library just adds an
15
+ this library instead.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4197"></a>Iterators</h2></div></div><div></div></div><p>The <tt class="filename">fox/iterators.rb</tt> library just adds an
16
16
  <tt class="methodname">each</tt> instance method for the <tt class="classname">
17
17
  FXComboBox</tt>, <tt class="classname">FXGLGroup</tt>, <tt class="classname">
18
18
  FXHeader</tt>, <tt class="classname">FXIconList</tt>, <tt class="classname">
@@ -21,10 +21,10 @@ dc.background = FXColor::MidnightBlue # instead of FXRGB( 25, 25, 112)</pre><
21
21
  FXTreeList</tt> and <tt class="classname">FXTreeListBox</tt> classes,
22
22
  so that you can iterate over their members in a Ruby-friendly way. It
23
23
  also mixes the <tt class="classname">Enumerable</tt> module into each of
24
- these classes.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4156"></a>Key Codes</h2></div></div><div></div></div><p>The <tt class="filename">fox/keys.rb</tt> library file defines all of the
24
+ these classes.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4241"></a>Key Codes</h2></div></div><div></div></div><p>The <tt class="filename">fox/keys.rb</tt> library file defines all of the
25
25
  key codes (e.g. <tt class="constant">KEY_space</tt>) that might show up in the
26
26
  code field of an <tt class="classname">FXEvent</tt> instance. This file is
27
27
  loaded automatically when you
28
28
  </p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">require 'fox'</pre></td></tr></table><p> and
29
29
  so you should never need to load it
30
- directly.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4173"></a>Calendar Widget</h2></div></div><div></div></div><p>The <tt class="filename">fox/calendar.rb</tt> library file provides the <tt class="classname">FXCalendar</tt> widget, contributed by David Naseby.</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="differences.html">Prev</a>&nbsp;</td><td width="20%" align="center"><a accesskey="u" href="pt02.html">Up</a></td><td width="40%" align="right">&nbsp;<a accesskey="n" href="implementation.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby&nbsp;</td><td width="20%" align="center"><a accesskey="h" href="book.html">Home</a></td><td width="40%" align="right" valign="top">&nbsp;Appendix&nbsp;E.&nbsp;Implementation</td></tr></table></div></body></html>
30
+ directly.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e4258"></a>Calendar Widget</h2></div></div><div></div></div><p>The <tt class="filename">fox/calendar.rb</tt> library file provides the <tt class="classname">FXCalendar</tt> widget, contributed by David Naseby.</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="differences.html">Prev</a>&nbsp;</td><td width="20%" align="center"><a accesskey="u" href="pt02.html">Up</a></td><td width="40%" align="right">&nbsp;<a accesskey="n" href="implementation.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby&nbsp;</td><td width="20%" align="center"><a accesskey="h" href="book.html">Home</a></td><td width="40%" align="right" valign="top">&nbsp;Appendix&nbsp;E.&nbsp;Implementation</td></tr></table></div></body></html>
data/doc/opengl.html CHANGED
@@ -5,10 +5,10 @@
5
5
  widgets, and FXRuby in turn provides interfaces to those classes. By
6
6
  combining FXRuby with the OpenGL interface for Ruby (described below) you
7
7
  can develop very powerful 3-D graphics applications. This chapter gives
8
- you the information you'll need to get started.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3192"></a>What is OpenGL?</h2></div></div><div></div></div><p>OpenGL is a platform-independent API for 2D and 3D graphics. The
8
+ you the information you'll need to get started.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3277"></a>What is OpenGL?</h2></div></div><div></div></div><p>OpenGL is a platform-independent API for 2D and 3D graphics. The
9
9
  home page is <a href="http://www.opengl.org" target="_top">http://www.opengl.org</a>. Because it's a
10
10
  fairly open standard, highly optimized OpenGL drivers are available for
11
- most operating systems (including Windows and Linux).</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3200"></a>OpenGL Extensions for Ruby</h2></div></div><div></div></div><p>This extension module, developed by Yoshiyuki Kusano, provides
11
+ most operating systems (including Windows and Linux).</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3285"></a>OpenGL Extensions for Ruby</h2></div></div><div></div></div><p>This extension module, developed by Yoshiyuki Kusano, provides
12
12
  interfaces to not only the basic OpenGL API, but also the GLU and GLUT
13
13
  APIs. As of this writing, the currently released version is 0.32d and is
14
14
  available for download from <a href="http://www2.giganet.net/~yoshi/rbogl-0.32b.tgz" target="_top">http://www2.giganet.net/~yoshi/rbogl-0.32d.tgz</a>.
@@ -25,7 +25,7 @@
25
25
  extensions by typing:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="screen">$ <b class="command">make site-install</b></pre></td></tr></table><p>Please note that I'm not the maintainer of this particular Ruby
26
26
  extension, so I can't really accept bug fixes for it. But if you're having
27
27
  trouble integrating Ruby/OpenGL with FXRuby, let me know and we'll see
28
- what we can do.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3255"></a>The FXGLVisual Class</h2></div></div><div></div></div><p>An <tt class="classname">FXGLVisual</tt> object describes the
28
+ what we can do.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3340"></a>The FXGLVisual Class</h2></div></div><div></div></div><p>An <tt class="classname">FXGLVisual</tt> object describes the
29
29
  capabilities of an <tt class="classname">FXGLCanvas</tt> or
30
30
  <tt class="classname">FXGLViewer</tt> window. Typically, an X server supports
31
31
  many different visuals with varying capabilities, but the ones with
@@ -58,13 +58,13 @@ end</pre></td></tr></table><p>Some <tt class="classname">FXGLVisual</tt> object
58
58
  separate <tt class="classname">FXGLVisual</tt> object for each window. For
59
59
  most applications, you can just construct a single
60
60
  <tt class="classname">FXGLVisual</tt> object that's shared among all the
61
- OpenGL windows.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3314"></a>The FXGLCanvas Class</h2></div></div><div></div></div><p>The <tt class="classname">FXGLCanvas</tt> widget provides a very simple
61
+ OpenGL windows.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3399"></a>The FXGLCanvas Class</h2></div></div><div></div></div><p>The <tt class="classname">FXGLCanvas</tt> widget provides a very simple
62
62
  OpenGL-capable window with minimal functionality. To construct an
63
63
  <tt class="classname">FXGLCanvas</tt>, call
64
64
  <tt class="methodname">FXGLCanvas.new</tt>:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">glCanvas = FXGLCanvas.new(parent, vis)</pre></td></tr></table><p>The first argument to <tt class="methodname">FXGLCanvas.new</tt> is the
65
65
  parent (container) widget and the second argument is the
66
66
  <tt class="classname">FXGLVisual</tt> that should be used for this
67
- window.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3338"></a>OpenGL objects and the FXGLViewer</h2></div></div><div></div></div><p>The <tt class="classname">FXGLViewer</tt> widget provides a higher-level
67
+ window.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3423"></a>OpenGL objects and the FXGLViewer</h2></div></div><div></div></div><p>The <tt class="classname">FXGLViewer</tt> widget provides a higher-level
68
68
  OpenGL-capable window with a lot of built-in functionality. To construct
69
69
  an <tt class="classname">FXGLViewer</tt>, call
70
70
  <tt class="methodname">FXGLViewer.new</tt>:</p><table border="0" bgcolor="#E0E0E0" width="100%"><tr><td><pre class="programlisting">glViewer = FXGLViewer.new(parent, vis)</pre></td></tr></table><p>The first argument to <tt class="methodname">FXGLViewer.new</tt> is the
data/doc/pt02.html CHANGED
@@ -1,3 +1,3 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Part&nbsp;II.&nbsp;Appendices</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="previous" href="changes.html" title="Chapter&nbsp;10.&nbsp;Change History"><link rel="next" href="opengl.html" title="Appendix&nbsp;A.&nbsp;Using OpenGL with FXRuby"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Part&nbsp;II.&nbsp;Appendices</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="changes.html">Prev</a>&nbsp;</td><th width="60%" align="center">&nbsp;</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="opengl.html">Next</a></td></tr></table><hr></div><div class="part" lang="en"><div class="titlepage"><div><div><h1 class="title"><a name="d0e3177"></a>Appendices</h1></div></div><div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt>A. <a href="opengl.html">Using OpenGL with FXRuby</a></dt><dt>B. <a href="scintilla.html">Using Scintilla with FXRuby</a></dt><dt>C. <a href="differences.html">Differences between FOX and FXRuby</a></dt><dt>D. <a href="library.html">The FXRuby Standard Library</a></dt><dt>E. <a href="implementation.html">Implementation</a></dt><dd><dl><dt><a href="implementation.html#d0e4187">Code Generation</a></dt><dt><a href="apes02.html">Object Life Cycles and Garbage Collection</a></dt><dd><dl><dt><a href="apes02.html#d0e4225">GL Objects</a></dt></dl></dd><dt><a href="apes03.html">Virtual Functions</a></dt></dl></dd><dt>F. <a href="cvs.html">Getting the Sources from CVS</a></dt></dl></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="changes.html">Prev</a>&nbsp;</td><td width="20%" align="center"><a accesskey="u" href="book.html">Up</a></td><td width="40%" align="right">&nbsp;<a accesskey="n" href="opengl.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter&nbsp;10.&nbsp;Change History&nbsp;</td><td width="20%" align="center"><a accesskey="h" href="book.html">Home</a></td><td width="40%" align="right" valign="top">&nbsp;Appendix&nbsp;A.&nbsp;Using OpenGL with FXRuby</td></tr></table></div></body></html>
3
+ <title>Part&nbsp;II.&nbsp;Appendices</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="previous" href="changes.html" title="Chapter&nbsp;10.&nbsp;Change History"><link rel="next" href="opengl.html" title="Appendix&nbsp;A.&nbsp;Using OpenGL with FXRuby"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Part&nbsp;II.&nbsp;Appendices</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="changes.html">Prev</a>&nbsp;</td><th width="60%" align="center">&nbsp;</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="opengl.html">Next</a></td></tr></table><hr></div><div class="part" lang="en"><div class="titlepage"><div><div><h1 class="title"><a name="d0e3262"></a>Appendices</h1></div></div><div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt>A. <a href="opengl.html">Using OpenGL with FXRuby</a></dt><dt>B. <a href="scintilla.html">Using Scintilla with FXRuby</a></dt><dt>C. <a href="differences.html">Differences between FOX and FXRuby</a></dt><dt>D. <a href="library.html">The FXRuby Standard Library</a></dt><dt>E. <a href="implementation.html">Implementation</a></dt><dd><dl><dt><a href="implementation.html#d0e4272">Code Generation</a></dt><dt><a href="apes02.html">Object Life Cycles and Garbage Collection</a></dt><dd><dl><dt><a href="apes02.html#d0e4310">GL Objects</a></dt></dl></dd><dt><a href="apes03.html">Virtual Functions</a></dt></dl></dd><dt>F. <a href="cvs.html">Getting the Sources from CVS</a></dt></dl></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="changes.html">Prev</a>&nbsp;</td><td width="20%" align="center"><a accesskey="u" href="book.html">Up</a></td><td width="40%" align="right">&nbsp;<a accesskey="n" href="opengl.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter&nbsp;10.&nbsp;Change History&nbsp;</td><td width="20%" align="center"><a accesskey="h" href="book.html">Home</a></td><td width="40%" align="right" valign="top">&nbsp;Appendix&nbsp;A.&nbsp;Using OpenGL with FXRuby</td></tr></table></div></body></html>
data/doc/scintilla.html CHANGED
@@ -1,12 +1,12 @@
1
1
  <html><head>
2
2
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
3
- <title>Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"><link rel="previous" href="opengl.html" title="Appendix&nbsp;A.&nbsp;Using OpenGL with FXRuby"><link rel="next" href="differences.html" title="Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="opengl.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;II.&nbsp;Appendices</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="differences.html">Next</a></td></tr></table><hr></div><div class="appendix" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="scintilla"></a>Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby</h2></div></div><div></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3365"></a>What is Scintilla?</h2></div></div><div></div></div><p><a href="http://www.scintilla.org" target="_top">Scintilla</a> is a free
3
+ <title>Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="book.html" title="Developing Graphical User Interfaces with FXRuby"><link rel="up" href="pt02.html" title="Part&nbsp;II.&nbsp;Appendices"><link rel="previous" href="opengl.html" title="Appendix&nbsp;A.&nbsp;Using OpenGL with FXRuby"><link rel="next" href="differences.html" title="Appendix&nbsp;C.&nbsp;Differences between FOX and FXRuby"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="opengl.html">Prev</a>&nbsp;</td><th width="60%" align="center">Part&nbsp;II.&nbsp;Appendices</th><td width="20%" align="right">&nbsp;<a accesskey="n" href="differences.html">Next</a></td></tr></table><hr></div><div class="appendix" lang="en"><div class="titlepage"><div><div><h2 class="title"><a name="scintilla"></a>Appendix&nbsp;B.&nbsp;Using Scintilla with FXRuby</h2></div></div><div></div></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3450"></a>What is Scintilla?</h2></div></div><div></div></div><p><a href="http://www.scintilla.org" target="_top">Scintilla</a> is a free
4
4
  source code editing component developed by Neil Hodgson for the Win32 and
5
- GTK+ platforms.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3372"></a>What is FXScintilla?</h2></div></div><div></div></div><p><a href="http://savannah.gnu.org/projects/fxscintilla" target="_top">FXScintilla </a> is
5
+ GTK+ platforms.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3457"></a>What is FXScintilla?</h2></div></div><div></div></div><p><a href="http://savannah.gnu.org/projects/fxscintilla" target="_top">FXScintilla </a> is
6
6
  a FOX widget that wraps around the Scintilla component, or, if you wish,
7
7
  the FOX "port" of Scintilla. It is being developed by Gilles Filippini,
8
8
  and as of this writing the latest release is available for download from
9
- <a href="http://savannah.nongnu.org/download/fxscintilla/fxscintilla-1.63.tar.gz" target="_top">http://savannah.nongnu.org/download/fxscintilla/fxscintilla-1.63.tar.gz</a>.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3382"></a>Compiling FXScintilla</h2></div></div><div></div></div><p>The FXScintilla distribution contains everything you need to build
9
+ <a href="http://savannah.nongnu.org/download/fxscintilla/fxscintilla-1.63.tar.gz" target="_top">http://savannah.nongnu.org/download/fxscintilla/fxscintilla-1.63.tar.gz</a>.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3467"></a>Compiling FXScintilla</h2></div></div><div></div></div><p>The FXScintilla distribution contains everything you need to build
10
10
  the FXScintilla widget and begin using it in your C++-based FOX
11
11
  applications. That is to say, you do not have to separately download the
12
12
  Scintilla source code from the Scintilla home page. When you unpack the
@@ -17,7 +17,7 @@
17
17
  other open-source software (like FOX) from the source code. The
18
18
  <tt class="filename">INSTALL</tt> file in the top-level directory should
19
19
  provide enough instruction for you to build and install FXScintilla for
20
- either Unix or Microsoft Windows.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3395"></a>Enabling FXScintilla Support in FXRuby</h2></div></div><div></div></div><p>The next step is to build a version of FXRuby (from its source code)
20
+ either Unix or Microsoft Windows.</p></div><div class="simplesect" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3480"></a>Enabling FXScintilla Support in FXRuby</h2></div></div><div></div></div><p>The next step is to build a version of FXRuby (from its source code)
21
21
  with the optional FXScintilla support enabled. If you're working on a Unix
22
22
  or Linux system and have installed FXScintilla in one of the standard
23
23
  installation directories (e.g. under <tt class="filename">/usr/include</tt> or <tt class="filename">/usr/local/include</tt>), the regular FXRuby build
@@ -527,50 +527,48 @@ SWIGIMPORT(void) SWIG_Ruby_ConvertPacked(VALUE obj, void *ptr, int sz, swig_ty
527
527
  #define SWIGTYPE_p_FXIconDict swig_types[8]
528
528
  #define SWIGTYPE_p_FXShell swig_types[9]
529
529
  #define SWIGTYPE_p_FXPopup swig_types[10]
530
- #define SWIGTYPE_p_FXTimer swig_types[11]
531
- #define SWIGTYPE_p_FXRootWindow swig_types[12]
532
- #define SWIGTYPE_p_FXWindow swig_types[13]
533
- #define SWIGTYPE_p_FXTopWindow swig_types[14]
534
- #define SWIGTYPE_p_void swig_types[15]
535
- #define SWIGTYPE_p_FXDocument swig_types[16]
536
- #define SWIGTYPE_p_FXRecentFiles swig_types[17]
537
- #define SWIGTYPE_p_FXMainWindow swig_types[18]
538
- #define SWIGTYPE_p_FXSplashWindow swig_types[19]
539
- #define SWIGTYPE_p_FXIcon swig_types[20]
540
- #define SWIGTYPE_p_FXID swig_types[21]
541
- #define SWIGTYPE_p_FXMutex swig_types[22]
542
- #define SWIGTYPE_p_FXEvent swig_types[23]
543
- #define SWIGTYPE_p_FXObject swig_types[24]
544
- #define SWIGTYPE_p_FXStringDict swig_types[25]
545
- #define SWIGTYPE_p_FXBitmap swig_types[26]
546
- #define SWIGTYPE_p_FXRectangle swig_types[27]
547
- #define SWIGTYPE_p_FXString swig_types[28]
548
- #define SWIGTYPE_p_FXPoint swig_types[29]
549
- #define SWIGTYPE_p_FXFileDict swig_types[30]
530
+ #define SWIGTYPE_p_FXRootWindow swig_types[11]
531
+ #define SWIGTYPE_p_FXWindow swig_types[12]
532
+ #define SWIGTYPE_p_FXTopWindow swig_types[13]
533
+ #define SWIGTYPE_p_void swig_types[14]
534
+ #define SWIGTYPE_p_FXDocument swig_types[15]
535
+ #define SWIGTYPE_p_FXRecentFiles swig_types[16]
536
+ #define SWIGTYPE_p_FXMainWindow swig_types[17]
537
+ #define SWIGTYPE_p_FXSplashWindow swig_types[18]
538
+ #define SWIGTYPE_p_FXIcon swig_types[19]
539
+ #define SWIGTYPE_p_FXID swig_types[20]
540
+ #define SWIGTYPE_p_FXMutex swig_types[21]
541
+ #define SWIGTYPE_p_FXEvent swig_types[22]
542
+ #define SWIGTYPE_p_FXObject swig_types[23]
543
+ #define SWIGTYPE_p_FXStringDict swig_types[24]
544
+ #define SWIGTYPE_p_FXBitmap swig_types[25]
545
+ #define SWIGTYPE_p_FXRectangle swig_types[26]
546
+ #define SWIGTYPE_p_FXString swig_types[27]
547
+ #define SWIGTYPE_p_FXPoint swig_types[28]
548
+ #define SWIGTYPE_p_FXFileDict swig_types[29]
549
+ #define SWIGTYPE_p_FXDebugTarget swig_types[30]
550
550
  #define SWIGTYPE_p_FXDataTarget swig_types[31]
551
- #define SWIGTYPE_p_FXDebugTarget swig_types[32]
551
+ #define SWIGTYPE_p_FXDelegator swig_types[32]
552
552
  #define SWIGTYPE_p_FXDrawable swig_types[33]
553
553
  #define SWIGTYPE_p_FXCursor swig_types[34]
554
- #define SWIGTYPE_p_FXDelegator swig_types[35]
555
- #define SWIGTYPE_p_FXCURCursor swig_types[36]
556
- #define SWIGTYPE_p_FXGIFCursor swig_types[37]
557
- #define SWIGTYPE_p_FXStream swig_types[38]
558
- #define SWIGTYPE_p_FXFontDesc swig_types[39]
559
- #define SWIGTYPE_p_FXApp swig_types[40]
560
- #define SWIGTYPE_p_FXChore swig_types[41]
561
- #define SWIGTYPE_p_FXRegion swig_types[42]
562
- #define SWIGTYPE_p_FXColor swig_types[43]
563
- #define SWIGTYPE_p_FXSize swig_types[44]
564
- #define SWIGTYPE_p_p_FXchar swig_types[45]
565
- #define SWIGTYPE_p_FXFont swig_types[46]
566
- #define SWIGTYPE_p_FXchar swig_types[47]
567
- #define SWIGTYPE_p_FXFrame swig_types[48]
568
- #define SWIGTYPE_p_FXFileAssoc swig_types[49]
569
- #define SWIGTYPE_p_FXVisual swig_types[50]
570
- #define SWIGTYPE_p_FXuint swig_types[51]
571
- #define SWIGTYPE_p_FXFileStream swig_types[52]
572
- #define SWIGTYPE_p_FXMemoryStream swig_types[53]
573
- static swig_type_info *swig_types[55];
554
+ #define SWIGTYPE_p_FXCURCursor swig_types[35]
555
+ #define SWIGTYPE_p_FXGIFCursor swig_types[36]
556
+ #define SWIGTYPE_p_FXStream swig_types[37]
557
+ #define SWIGTYPE_p_FXFontDesc swig_types[38]
558
+ #define SWIGTYPE_p_FXApp swig_types[39]
559
+ #define SWIGTYPE_p_FXRegion swig_types[40]
560
+ #define SWIGTYPE_p_FXColor swig_types[41]
561
+ #define SWIGTYPE_p_FXSize swig_types[42]
562
+ #define SWIGTYPE_p_p_FXchar swig_types[43]
563
+ #define SWIGTYPE_p_FXFont swig_types[44]
564
+ #define SWIGTYPE_p_FXchar swig_types[45]
565
+ #define SWIGTYPE_p_FXFrame swig_types[46]
566
+ #define SWIGTYPE_p_FXFileAssoc swig_types[47]
567
+ #define SWIGTYPE_p_FXVisual swig_types[48]
568
+ #define SWIGTYPE_p_FXuint swig_types[49]
569
+ #define SWIGTYPE_p_FXFileStream swig_types[50]
570
+ #define SWIGTYPE_p_FXMemoryStream swig_types[51]
571
+ static swig_type_info *swig_types[53];
574
572
 
575
573
  /* -------- TYPES TABLE (END) -------- */
576
574
 
@@ -919,10 +917,6 @@ static void free_FXAccelTable(FXAccelTable *);
919
917
 
920
918
  swig_class cFXEvent;
921
919
  static void free_FXEvent(FXEvent *);
922
-
923
- swig_class cFXChore;
924
-
925
- swig_class cFXTimer;
926
920
  VALUE FXApp_copyright(){
927
921
  return rb_str_new2((const char *) FXApp::copyright);
928
922
  }
@@ -3180,14 +3174,14 @@ static VALUE _wrap_FXApp_addTimeout(int argc, VALUE *argv, VALUE self) { FXApp *
3180
3174
  if ((argc < 2) || (argc > 4)) rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc);
3181
3175
  SWIG_ConvertPtr(self, (void **) &arg1, SWIGTYPE_p_FXApp, 1);
3182
3176
  SWIG_ConvertPtr(argv[0], (void **) &arg2, SWIGTYPE_p_FXObject, 1); arg3 = NUM2UINT(argv[1]); if (argc > 2) {
3183
- arg4 = NUM2UINT(argv[2]); } if (argc > 3) { SWIG_ConvertPtr(argv[3], (void **) &arg5, 0, 1); }
3177
+ arg4 = NUM2UINT(argv[2]); } if (argc > 3) { arg5 = (argv[3] == Qnil) ? NULL : (void *) argv[3]; }
3184
3178
  (arg1)->addTimeout(arg2,arg3,arg4,arg5); return Qnil; }
3185
3179
  static VALUE _wrap_FXApp_removeTimeout(int argc, VALUE *argv, VALUE self) { FXApp *arg1 = (FXApp *) 0 ;
3186
3180
  FXObject *arg2 = (FXObject *) 0 ; FXSelector arg3 ; if ((argc < 2) || (argc > 2))
3187
3181
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_ConvertPtr(self, (void **) &arg1, SWIGTYPE_p_FXApp, 1);
3188
3182
  SWIG_ConvertPtr(argv[0], (void **) &arg2, SWIGTYPE_p_FXObject, 1); arg3 = NUM2UINT(argv[1]);
3189
3183
  (arg1)->removeTimeout(arg2,arg3); return Qnil; }
3190
- static VALUE _wrap_FXApp_hasTimeoutq___(int argc, VALUE *argv, VALUE self) { FXApp *arg1 = (FXApp *) 0 ;
3184
+ static VALUE _wrap_FXApp_hasTimeout(int argc, VALUE *argv, VALUE self) { FXApp *arg1 = (FXApp *) 0 ;
3191
3185
  FXObject *arg2 = (FXObject *) 0 ; FXSelector arg3 ; FXbool result; VALUE vresult = Qnil; if ((argc < 2) || (argc > 2))
3192
3186
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_ConvertPtr(self, (void **) &arg1, SWIGTYPE_p_FXApp, 1);
3193
3187
  SWIG_ConvertPtr(argv[0], (void **) &arg2, SWIGTYPE_p_FXObject, 1); arg3 = NUM2UINT(argv[1]);
@@ -3204,13 +3198,13 @@ static VALUE _wrap_FXApp_addChore(int argc, VALUE *argv, VALUE self) { FXApp *ar
3204
3198
  FXObject *arg2 = (FXObject *) 0 ; FXSelector arg3 ; void *arg4 = (void *) 0 ; if ((argc < 2) || (argc > 3))
3205
3199
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_ConvertPtr(self, (void **) &arg1, SWIGTYPE_p_FXApp, 1);
3206
3200
  SWIG_ConvertPtr(argv[0], (void **) &arg2, SWIGTYPE_p_FXObject, 1); arg3 = NUM2UINT(argv[1]); if (argc > 2) {
3207
- SWIG_ConvertPtr(argv[2], (void **) &arg4, 0, 1); } (arg1)->addChore(arg2,arg3,arg4); return Qnil; }
3201
+ arg4 = (argv[2] == Qnil) ? NULL : (void *) argv[2]; } (arg1)->addChore(arg2,arg3,arg4); return Qnil; }
3208
3202
  static VALUE _wrap_FXApp_removeChore(int argc, VALUE *argv, VALUE self) { FXApp *arg1 = (FXApp *) 0 ;
3209
3203
  FXObject *arg2 = (FXObject *) 0 ; FXSelector arg3 ; if ((argc < 2) || (argc > 2))
3210
3204
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_ConvertPtr(self, (void **) &arg1, SWIGTYPE_p_FXApp, 1);
3211
3205
  SWIG_ConvertPtr(argv[0], (void **) &arg2, SWIGTYPE_p_FXObject, 1); arg3 = NUM2UINT(argv[1]); (arg1)->removeChore(arg2,arg3);
3212
3206
  return Qnil; }
3213
- static VALUE _wrap_FXApp_hasChoreq___(int argc, VALUE *argv, VALUE self) { FXApp *arg1 = (FXApp *) 0 ;
3207
+ static VALUE _wrap_FXApp_hasChore(int argc, VALUE *argv, VALUE self) { FXApp *arg1 = (FXApp *) 0 ;
3214
3208
  FXObject *arg2 = (FXObject *) 0 ; FXSelector arg3 ; FXbool result; VALUE vresult = Qnil; if ((argc < 2) || (argc > 2))
3215
3209
  rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_ConvertPtr(self, (void **) &arg1, SWIGTYPE_p_FXApp, 1);
3216
3210
  SWIG_ConvertPtr(argv[0], (void **) &arg2, SWIGTYPE_p_FXObject, 1); arg3 = NUM2UINT(argv[1]);
@@ -8849,7 +8843,6 @@ static swig_type_info _swigt__p_FXId[] = {{"_p_FXId", 0, "FXId *", 0, 0, 0, 0},{
8849
8843
  static swig_type_info _swigt__p_FXIconDict[] = {{"_p_FXIconDict", 0, "FXIconDict *", 0, 0, 0, 0},{"_p_FXIconDict", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8850
8844
  static swig_type_info _swigt__p_FXShell[] = {{"_p_FXShell", 0, "FXShell *", 0, 0, 0, 0},{"_p_FXShell", 0, 0, 0, 0, 0, 0},{"_p_FXPopup", _p_FXPopupTo_p_FXShell, 0, 0, 0, 0, 0},{"_p_FXTopWindow", _p_FXTopWindowTo_p_FXShell, 0, 0, 0, 0, 0},{"_p_FXMainWindow", _p_FXMainWindowTo_p_FXShell, 0, 0, 0, 0, 0},{"_p_FXSplashWindow", _p_FXSplashWindowTo_p_FXShell, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8851
8845
  static swig_type_info _swigt__p_FXPopup[] = {{"_p_FXPopup", 0, "FXPopup *", 0, 0, 0, 0},{"_p_FXPopup", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8852
- static swig_type_info _swigt__p_FXTimer[] = {{"_p_FXTimer", 0, "FXTimer *", 0, 0, 0, 0},{"_p_FXTimer", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8853
8846
  static swig_type_info _swigt__p_FXRootWindow[] = {{"_p_FXRootWindow", 0, "FXRootWindow *", 0, 0, 0, 0},{"_p_FXRootWindow", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8854
8847
  static swig_type_info _swigt__p_FXWindow[] = {{"_p_FXWindow", 0, "FXWindow *", 0, 0, 0, 0},{"_p_FXComposite", _p_FXCompositeTo_p_FXWindow, 0, 0, 0, 0, 0},{"_p_FXShell", _p_FXShellTo_p_FXWindow, 0, 0, 0, 0, 0},{"_p_FXWindow", 0, 0, 0, 0, 0, 0},{"_p_FXPopup", _p_FXPopupTo_p_FXWindow, 0, 0, 0, 0, 0},{"_p_FXTopWindow", _p_FXTopWindowTo_p_FXWindow, 0, 0, 0, 0, 0},{"_p_FXMainWindow", _p_FXMainWindowTo_p_FXWindow, 0, 0, 0, 0, 0},{"_p_FXSplashWindow", _p_FXSplashWindowTo_p_FXWindow, 0, 0, 0, 0, 0},{"_p_FXRootWindow", _p_FXRootWindowTo_p_FXWindow, 0, 0, 0, 0, 0},{"_p_FXFrame", _p_FXFrameTo_p_FXWindow, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8855
8848
  static swig_type_info _swigt__p_FXTopWindow[] = {{"_p_FXTopWindow", 0, "FXTopWindow *", 0, 0, 0, 0},{"_p_FXTopWindow", 0, 0, 0, 0, 0, 0},{"_p_FXMainWindow", _p_FXMainWindowTo_p_FXTopWindow, 0, 0, 0, 0, 0},{"_p_FXSplashWindow", _p_FXSplashWindowTo_p_FXTopWindow, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
@@ -8869,17 +8862,16 @@ static swig_type_info _swigt__p_FXRectangle[] = {{"_p_FXRectangle", 0, "FXRectan
8869
8862
  static swig_type_info _swigt__p_FXString[] = {{"_p_FXString", 0, "FXString *", 0, 0, 0, 0},{"_p_FXString", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8870
8863
  static swig_type_info _swigt__p_FXPoint[] = {{"_p_FXPoint", 0, "FXPoint *", 0, 0, 0, 0},{"_p_FXPoint", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8871
8864
  static swig_type_info _swigt__p_FXFileDict[] = {{"_p_FXFileDict", 0, "FXFileDict *", 0, 0, 0, 0},{"_p_FXFileDict", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8872
- static swig_type_info _swigt__p_FXDataTarget[] = {{"_p_FXDataTarget", 0, "FXDataTarget *", 0, 0, 0, 0},{"_p_FXDataTarget", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8873
8865
  static swig_type_info _swigt__p_FXDebugTarget[] = {{"_p_FXDebugTarget", 0, "FXDebugTarget *", 0, 0, 0, 0},{"_p_FXDebugTarget", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8866
+ static swig_type_info _swigt__p_FXDataTarget[] = {{"_p_FXDataTarget", 0, "FXDataTarget *", 0, 0, 0, 0},{"_p_FXDataTarget", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8867
+ static swig_type_info _swigt__p_FXDelegator[] = {{"_p_FXDelegator", 0, "FXDelegator *", 0, 0, 0, 0},{"_p_FXDelegator", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8874
8868
  static swig_type_info _swigt__p_FXDrawable[] = {{"_p_FXDrawable", 0, "FXDrawable *", 0, 0, 0, 0},{"_p_FXComposite", _p_FXCompositeTo_p_FXDrawable, 0, 0, 0, 0, 0},{"_p_FXShell", _p_FXShellTo_p_FXDrawable, 0, 0, 0, 0, 0},{"_p_FXPopup", _p_FXPopupTo_p_FXDrawable, 0, 0, 0, 0, 0},{"_p_FXTopWindow", _p_FXTopWindowTo_p_FXDrawable, 0, 0, 0, 0, 0},{"_p_FXMainWindow", _p_FXMainWindowTo_p_FXDrawable, 0, 0, 0, 0, 0},{"_p_FXSplashWindow", _p_FXSplashWindowTo_p_FXDrawable, 0, 0, 0, 0, 0},{"_p_FXRootWindow", _p_FXRootWindowTo_p_FXDrawable, 0, 0, 0, 0, 0},{"_p_FXWindow", _p_FXWindowTo_p_FXDrawable, 0, 0, 0, 0, 0},{"_p_FXDrawable", 0, 0, 0, 0, 0, 0},{"_p_FXFrame", _p_FXFrameTo_p_FXDrawable, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8875
8869
  static swig_type_info _swigt__p_FXCursor[] = {{"_p_FXCursor", 0, "FXCursor *", 0, 0, 0, 0},{"_p_FXCursor", 0, 0, 0, 0, 0, 0},{"_p_FXCURCursor", _p_FXCURCursorTo_p_FXCursor, 0, 0, 0, 0, 0},{"_p_FXGIFCursor", _p_FXGIFCursorTo_p_FXCursor, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8876
- static swig_type_info _swigt__p_FXDelegator[] = {{"_p_FXDelegator", 0, "FXDelegator *", 0, 0, 0, 0},{"_p_FXDelegator", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8877
8870
  static swig_type_info _swigt__p_FXCURCursor[] = {{"_p_FXCURCursor", 0, "FXCURCursor *", 0, 0, 0, 0},{"_p_FXCURCursor", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8878
8871
  static swig_type_info _swigt__p_FXGIFCursor[] = {{"_p_FXGIFCursor", 0, "FXGIFCursor *", 0, 0, 0, 0},{"_p_FXGIFCursor", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8879
8872
  static swig_type_info _swigt__p_FXStream[] = {{"_p_FXStream", 0, "FXStream *", 0, 0, 0, 0},{"_p_FXFileStream", _p_FXFileStreamTo_p_FXStream, 0, 0, 0, 0, 0},{"_p_FXMemoryStream", _p_FXMemoryStreamTo_p_FXStream, 0, 0, 0, 0, 0},{"_p_FXStream", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8880
8873
  static swig_type_info _swigt__p_FXFontDesc[] = {{"_p_FXFontDesc", 0, "FXFontDesc *", 0, 0, 0, 0},{"_p_FXFontDesc", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8881
8874
  static swig_type_info _swigt__p_FXApp[] = {{"_p_FXApp", 0, "FXApp *", 0, 0, 0, 0},{"_p_FXApp", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8882
- static swig_type_info _swigt__p_FXChore[] = {{"_p_FXChore", 0, "FXChore *", 0, 0, 0, 0},{"_p_FXChore", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8883
8875
  static swig_type_info _swigt__p_FXRegion[] = {{"_p_FXRegion", 0, "FXRegion *", 0, 0, 0, 0},{"_p_FXRegion", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8884
8876
  static swig_type_info _swigt__p_FXColor[] = {{"_p_FXColor", 0, "unsigned int const *|FXColor const *", 0, 0, 0, 0},{"_p_FXuint", 0, 0, 0, 0, 0, 0},{"_p_FXColor", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
8885
8877
  static swig_type_info _swigt__p_FXSize[] = {{"_p_FXSize", 0, "FXSize *", 0, 0, 0, 0},{"_p_FXSize", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
@@ -8905,7 +8897,6 @@ _swigt__p_FXId,
8905
8897
  _swigt__p_FXIconDict,
8906
8898
  _swigt__p_FXShell,
8907
8899
  _swigt__p_FXPopup,
8908
- _swigt__p_FXTimer,
8909
8900
  _swigt__p_FXRootWindow,
8910
8901
  _swigt__p_FXWindow,
8911
8902
  _swigt__p_FXTopWindow,
@@ -8925,17 +8916,16 @@ _swigt__p_FXRectangle,
8925
8916
  _swigt__p_FXString,
8926
8917
  _swigt__p_FXPoint,
8927
8918
  _swigt__p_FXFileDict,
8928
- _swigt__p_FXDataTarget,
8929
8919
  _swigt__p_FXDebugTarget,
8920
+ _swigt__p_FXDataTarget,
8921
+ _swigt__p_FXDelegator,
8930
8922
  _swigt__p_FXDrawable,
8931
8923
  _swigt__p_FXCursor,
8932
- _swigt__p_FXDelegator,
8933
8924
  _swigt__p_FXCURCursor,
8934
8925
  _swigt__p_FXGIFCursor,
8935
8926
  _swigt__p_FXStream,
8936
8927
  _swigt__p_FXFontDesc,
8937
8928
  _swigt__p_FXApp,
8938
- _swigt__p_FXChore,
8939
8929
  _swigt__p_FXRegion,
8940
8930
  _swigt__p_FXColor,
8941
8931
  _swigt__p_FXSize,
@@ -9379,18 +9369,6 @@ SWIGEXPORT(void) Init_core(void) {
9379
9369
  cFXEvent.mark = 0;
9380
9370
  cFXEvent.destroy = (void (*)(void *)) FXRbUnregisterRubyObj;
9381
9371
 
9382
- cFXChore.klass = rb_define_class_under(mFox, "FXChore", rb_cObject);
9383
- SWIG_TypeClientData(SWIGTYPE_p_FXChore, (void *) &cFXChore);
9384
- rb_undef_alloc_func(cFXChore.klass);
9385
- cFXChore.mark = 0;
9386
- cFXChore.destroy = (void (*)(void *)) FXRbUnregisterRubyObj;
9387
-
9388
- cFXTimer.klass = rb_define_class_under(mFox, "FXTimer", rb_cObject);
9389
- SWIG_TypeClientData(SWIGTYPE_p_FXTimer, (void *) &cFXTimer);
9390
- rb_undef_alloc_func(cFXTimer.klass);
9391
- cFXTimer.mark = 0;
9392
- cFXTimer.destroy = (void (*)(void *)) FXRbUnregisterRubyObj;
9393
-
9394
9372
  cFXApp.klass = rb_define_class_under(mFox, "FXApp", ((swig_class *) SWIGTYPE_p_FXObject->clientdata)->klass);
9395
9373
  SWIG_TypeClientData(SWIGTYPE_p_FXApp, (void *) &cFXApp);
9396
9374
  rb_define_alloc_func(cFXApp.klass, _wrap_FXApp_allocate);
@@ -9423,12 +9401,12 @@ SWIGEXPORT(void) Init_core(void) {
9423
9401
  rb_define_method(cFXApp.klass, "findWindowAt", VALUEFUNC(_wrap_FXApp_findWindowAt), -1);
9424
9402
  rb_define_method(cFXApp.klass, "addTimeout", VALUEFUNC(_wrap_FXApp_addTimeout), -1);
9425
9403
  rb_define_method(cFXApp.klass, "removeTimeout", VALUEFUNC(_wrap_FXApp_removeTimeout), -1);
9426
- rb_define_method(cFXApp.klass, "hasTimeout?", VALUEFUNC(_wrap_FXApp_hasTimeoutq___), -1);
9404
+ rb_define_method(cFXApp.klass, "hasTimeout", VALUEFUNC(_wrap_FXApp_hasTimeout), -1);
9427
9405
  rb_define_method(cFXApp.klass, "remainingTimeout", VALUEFUNC(_wrap_FXApp_remainingTimeout), -1);
9428
9406
  rb_define_method(cFXApp.klass, "handleTimeouts", VALUEFUNC(_wrap_FXApp_handleTimeouts), -1);
9429
9407
  rb_define_method(cFXApp.klass, "addChore", VALUEFUNC(_wrap_FXApp_addChore), -1);
9430
9408
  rb_define_method(cFXApp.klass, "removeChore", VALUEFUNC(_wrap_FXApp_removeChore), -1);
9431
- rb_define_method(cFXApp.klass, "hasChore?", VALUEFUNC(_wrap_FXApp_hasChoreq___), -1);
9409
+ rb_define_method(cFXApp.klass, "hasChore", VALUEFUNC(_wrap_FXApp_hasChore), -1);
9432
9410
  rb_define_method(cFXApp.klass, "addSignal", VALUEFUNC(_wrap_FXApp_addSignal), -1);
9433
9411
  rb_define_method(cFXApp.klass, "removeSignal", VALUEFUNC(_wrap_FXApp_removeSignal), -1);
9434
9412
  rb_define_method(cFXApp.klass, "addInput", VALUEFUNC(_wrap_FXApp_addInput), -1);