Commit Graph

324 Commits

Author SHA1 Message Date
Bill Spitzak
b45efe96dc Fixed the gl_overlay demo (and gl overlays in general) when they are
faked with no hardware and the window is resized.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@984 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2000-01-12 06:06:24 +00:00
Michael R Sweet
0bdb9aba79 Fixed background (@B) option - was drawing background for selected items.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@982 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2000-01-11 16:03:55 +00:00
Bill Spitzak
d43eac1e38 Programs can now resize() their windows even if they are not resizable()
on X (this already worked on Win32).
Changed the resize demo program to test this.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@981 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2000-01-11 08:20:02 +00:00
Bill Spitzak
49b8502b83 Added Fl.H required by an inline function if Fl_Repeat_Button.H
Fl_add_idle adds new functions to the end of the queue ring, rather than the
start, so they are executed in the order added, and a callback that adds
itself does not prevent others from being called.

Fluid lets you type in code that starts with '#' for cpp directives.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@969 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2000-01-05 03:17:28 +00:00
Michael R Sweet
c0cdc56926 Fixed async selection code - wasn't calling TranslateMessage...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@967 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-31 02:56:18 +00:00
Michael R Sweet
df57aa4d2f Re-integrated all of the old WIN32 select() code just in case it is needed
(undefine USE_ASYNC_SELECT to use the old code)

XBell() might be called before fl_display is initialized.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@966 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-30 17:37:05 +00:00
Michael R Sweet
30ce47ef69 New WSAAsyncSelect code for WIN32 Fl::add_fd() support.
Fixes for Fl_Scrollbar - pushed_ bits wrong...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@965 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-29 03:14:41 +00:00
Bill Spitzak
8251826357 Stuff that didn't get into 1.0.7:
Fix for Borland or other platforms where GLint != int.

Fixed browser scrollbars so they work if browser is inside a scroll
(it did not update their position to match where they were drawn)

Fl_Output (and non-focused Fl_Input) now scroll in response to position()
calls from the program to show the position.  In addition I cleaned up the
horizontal scrolling of Fl_Input to be less screwy, it now never scrolls
if the text actually fits in the widget.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@959 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-19 05:32:34 +00:00
Bill Spitzak
e7f42fa15f Fixed bug on Win32 where programs would stop paying attention to keys.
What actually happens is that GetKeyState() returns garbage for the
"windoze" keys if you hit them to pop up the start menu.  It now calls
GetAsyncKeyState(), which works.
Also this version calls TranslateEvent on all events before calling
DispatchEvent(), which is apparently what Win32 expects.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@948 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-15 04:58:27 +00:00
Michael R Sweet
a2b5dfc5d5 Added #ifdef's for OpenBSD and NetBSD...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@946 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-08 20:49:57 +00:00
Bill Spitzak
3e0db7129e Removed warning messages from gcc compile
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@942 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-07 17:53:09 +00:00
Michael R Sweet
1e3bc4ba57 Minor change - now check the version of Windows we have to
determine if we should use the built-in hand cursor instead of up-
arrow...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@936 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-06 14:43:40 +00:00
Michael R Sweet
6ffdd70246 FL_CURSOR_HAND should be IDC_HAND, not IDC_UPARROW.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@935 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-05 13:59:26 +00:00
Michael R Sweet
08ed55a14b Scrollbars now "page" when you click outside the scroller.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@934 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-04 12:22:37 +00:00
Bill Spitzak
6291a33526 Fixed warning message in Mike's fix to Fl::args
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@933 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-03 18:11:05 +00:00
Carl E. Thompson
6b60719c6d Fixes argc == 0 segfault.
Carl


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@930 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-12-01 15:49:28 +00:00
Carl E. Thompson
6e6261c5bd Fixed fl_call_main.c to compile with BC5. This fix is already in the 2.0
tree.

Carl


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@929 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-30 13:14:27 +00:00
Bill Spitzak
c05eed1e54 Correctly measures browser items with @C or @B color formatting commands.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@891 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-19 08:44:43 +00:00
Michael R Sweet
555f3eb3a7 Fixed bit reversal table - entry for reversing 1100 was set to 0010
instead of 0011!


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@887 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-18 17:12:55 +00:00
Michael R Sweet
ef8eaf25b8 Now set the label() of the message form appropriately (no more ***** in
the title bar!)

Now call MessageBeep() under WIN32 for all popups and XBell() for
fl_alert() under X11.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@885 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-18 16:33:01 +00:00
Michael R Sweet
89323df848 Fl_Browser_ didn't draw the selection box using an inactive color when
needed.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@880 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-16 14:44:43 +00:00
Bill Spitzak
9ce13e4fff Changes requested by Jeff Meininger
1. Browser responds to FL_KEYBOARD as well as FL_SHORTCUT.  If you subclass
it to accept focus then keyboard navigation will work.  I could not do his full
patch as it broke the file chooser's tab completion and perhaps other programs.

2. Fl_Tile and Fl_Tabs do their callback when the user changes their display.

3. Made some of the private methods of Fl_Browser protected.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@879 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-16 07:39:59 +00:00
Michael R Sweet
d1f909be8a fl_arc() and fl_pie() fixes for WIN32 removed - the problem is with
the SGI X server with small arcs & pies, and not with WIN32.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@858 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-12 00:19:14 +00:00
Bill Spitzak
b59a07f472 Sets win_gravity correctly, this helps some X window managers that use
it position the window where fltk wants it to be.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@836 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-10 09:18:31 +00:00
Michael R Sweet
20522b715e fl_arc() and fl_pie() were drawing 1 pixel too little horizontally and
vertically under WIN32 compared to X11.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@834 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-09 16:40:05 +00:00
Bill Spitzak
b23b10c7e0 Zero-width browsers crashed:
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@831 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-07 08:33:36 +00:00
Bill Spitzak
de5a005e69 Minor change: if the X window manager does not do anything else with windows
that don't have their position specified, the windows appear centered in
the screen, rather than in the top-left corner.  This happened with modal
windows under Irix 4Dwm.  This also causes windows to be centered when no
window manager is running, which might be useful for installation gui programs?


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@823 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-11-04 18:35:12 +00:00
Bill Spitzak
c3bd173a57 More fixes to the text editing to make the NT users happy.
With all the recent check-ins, the result is that text editing is a
combination of the best parts of "CUA" and X/Motif text editing
(in my opinion).  It mostly acts like CUA with these additions:

1. Clicking in a field the first time selects the entire field (this is a
necessary modification so that it works in point-to-type window managers
and still looks like Windoze, in Windoze it appears that all text fields
are switched to all-selected when the window is "activated").

2. The middle mouse button acts like the left one and *then* does "paste".
Unlike Motif you can replace text by selecting it with the middle mouse button.

3. *drag* of the left mouse button does "copy".  Unlike Motif, other methods
of selecting text (like double-click) does not do "copy".


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@807 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-30 20:21:30 +00:00
Michael R Sweet
936b75f917 C++ comments are not valid ANSI C source!!!!!!!!!!!!!
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@796 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-25 20:32:49 +00:00
Bill Spitzak
0627bd9a3e Does not call draw() on child Fl_Windows when their parent is hidden.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@793 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-23 06:19:59 +00:00
Bill Spitzak
ecd524fdc7 Calling deactivate() from a non-displayed widget could cause an infinite
loop.  I didn't really fix this, but I removed deactivate() from constructors
and replaced with set_flag(INACTIVE).  The loop would happen if a widget
responded to FL_MOVE by calling draw_overlay or otherwise creating an
overlay, which is a pretty rare event.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@792 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-23 05:59:27 +00:00
Bill Spitzak
06ea565dba Fixed configure uversion for Irix 6.5
Fix (untested) xparsecolor emulation on Win32 for #x where x != 6 digits


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@789 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-19 04:50:34 +00:00
Bill Spitzak
2e58f174f7 Changed the sgi -woff pragma to the new #define suggested by Michael Sweet.
Cast in draw_pixmap that produced an error in the OSF1 compiler fixed.

Error in emulation of GLUT_KEY_F?()


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@779 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-16 19:58:22 +00:00
Bill Spitzak
a7904da09a I fixed Fl_Tabs so that child tabs can be added/removed without any
concern if they are selected, it uses the first visible() child to
indicate the selected tab.

Fixed up rather bogus fix for selecting entire text field when you click
on it.  This new version does not do it for multi-line and does not
mess up the middle-mouse paste action.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@777 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-15 09:01:48 +00:00
Bill Spitzak
b9c6935372 Fixed the shiny demo (and a DD program). Note: this fix is not
in fltk 2.0.  It correctly draws the box behind a slider.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@776 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-15 08:14:37 +00:00
Bill Spitzak
ce249490d4 These are some (hopefully minor) changes we keep needing to edit into
each new version of fltk for use at Digital Domain.  These were found by
running a diff between 1.0.6 and our inhouse version.

1. WinMain is moved to the fl_call_main.c file so that it can easily be
conditionally-compiled out (code copied from fltk 2.0, not tested!)

2. Fl_win32 ignores the value of window->xclass().  This seemed to cause
problems when windows had different xclass() in the same app and did not
have any useful effect on windows.  This value is changed to set the icon
of the app on X.

3. sgi pragmas added to x.H to turn off warnings from their broken xlib
header files.  Please tell me if this causes any sgi compilers to complain,
we should add more stuff to the #ifdef to stop that.

4. Fl_Gl_Window::ortho() changed so that text and images are not erased
if the origin is off the left/bottom of the window.

5. Small change to Fl_Input so that a click that gives it the focus also
selects all the text.  This is more windoze-like and it seems the users
really like it.

Note also that we had to set USE_XDBE to zero to get things to work on
the newest Irix machines.  I give up, Xdbe has been nothing but an impossible
and confusing mess and it is obvious that the X servers are not testing it
and thus it is suffering from software rot so it is unlikely to work anywhere
in the future.  Not sure if we want to switch it off in the official version,
though.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@774 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-10-14 04:56:09 +00:00
Bill Spitzak
be101a57e6 Fl_Repeat_Button removes the timeout if it is deactivated or hidden
while it is still held down.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@739 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-09-20 04:27:24 +00:00
Bill Spitzak
c8794e2f58 Fixed some WIN32 bugs found in 1.0.5:
FL_MOUSELEAVE had an extra underscore
call to toupper() removed
const char* cast added to fl_draw_pixmap

Change to Fl_Gl_Window that did not get in in time for 1.0.5, it caches
the current gl context and does not call glXMakeCurrent (wglMakeCurrent
on WIN32) if not needed.  This distinctly speeds up Mesa, Irix, and
Windows opengl, although I am stumped why such a test is not built
into those libraries already.

If you use other code that sets the current OpenGL context fltk will
get confused because it does not know it changed.  To fix such programs
you must call fl_no_gl_context() to clear the cache.

There is a report that this causes the fractals demo to crash on some
Linux and Irix machines, although I can't reproduce it.  I suspect the
problem is the fractals demo and not fltk, but this change may be making
it more likely to fail.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@726 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-09-16 05:34:27 +00:00
Michael R Sweet
aa9c028aeb Added Fl_Roller fix from 2.0 tree.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@719 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-09-15 16:07:03 +00:00
Michael R Sweet
9afb77da56 Fixed long-standing bug reported by Rick Sayre in Fl_Browser_ - if the
draw code added a horizontal scrollbar it might not add the vertical one
until the next redraw.

Added FreeBSD to the list of platforms needing the scandir function cast.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@718 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-09-15 15:18:12 +00:00
Bill Spitzak
6b07587d74 Now correctly draws XPM files with 16-bit color indexes.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@674 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-08-25 05:37:40 +00:00
gustavo
138c7287b2 Changed call_timeouts() and Fl::wait()/wait(double). The wait functions will now return immediately (do fl_wait(0,0)) if any timeouts were called in call_timeouts(). Motivation: An event loop like
while (work_to_do) {
	work_some();
	Fl::check();
    } else {
	Fl::wait();
    }

    Suppose that a timeout sets the work_to_do flag, which is initially cleared.
    Fl::wait() will wait for this timeout, return, then expire the timeout and wait for user input.
    With the fix, it will work as expected.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@669 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-08-22 23:31:21 +00:00
Bill Spitzak
7508ce1e31 It crashed when a group with exactly 1 child was deleted.
Overlay on a single buffered Fl_Gl_Window is faked more accurately when
there is no overlay hardware.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@639 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-08-09 06:19:33 +00:00
Bill Spitzak
f7e0e7627f Can draw xpm pixmaps with spaces in the color names (such as the ones in
/usr/X11/include/X11/icons).
Esc closes the modal window, not the window the cursor is in, if a modal
window is up.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@632 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-07-27 17:24:14 +00:00
Bill Spitzak
df045b0e36 FL_KEYBOARD events have the correct x/y when sent to child X windows.
Notice that if you worked around this bug by adjusting the x/y yourself
you will have to change your code.

In addition all events have the correct x/y when sent to the grab()
widget.  And the code to do all this was simplified a lot.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@630 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-07-22 21:37:04 +00:00
Bill Spitzak
0bb590c832 Pragma added around xlib.h to shut up the IRIX compiler warnings
Fluid writes "class foo;" to the header and c file without prepending
"extern" or "static".  This patch also does this to "class foo bar;"
which is wrong...

Tabs draw very short labels.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@629 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-07-22 07:27:12 +00:00
Carl E. Thompson
ae621ef778 Fixed core dump when drawing with a font but it hadn't been previous set.
Carl


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@625 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-07-21 01:21:49 +00:00
Carl E. Thompson
4da7a06300 Removed patch - didn't fix problem.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@624 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-07-12 12:22:45 +00:00
Michael R Sweet
4acc49c207 Testing a possible Fl_Menu_::add() bug fix...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@623 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-07-12 11:59:03 +00:00
Michael R Sweet
5dadca9c90 Added "delete local_array[]" to Fl_Menu_Item::insert().
Moved value_->hide() in Fl_Tabs::value() before show to avoid bug when
there is only 1 child (fix from Petr Vilim).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@620 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-07-06 16:16:38 +00:00
Michael R Sweet
971dc6583b Was escaping characters from 0x80 to 0x9f, but these are used by the
PostScript and Windows ISOLatin1 encodings (and the X11 fonts which use
them...)  Commented the code out for now...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@609 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-06-16 15:14:42 +00:00
Michael R Sweet
fbc03d29f1 Put curley braces around selection clear code to work around
VC++ variable scoping bug...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@604 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-06-12 15:09:19 +00:00
Michael R Sweet
b846b2515a Final fix (I hope) for WIN32 selection code (now check against all windows
and only clear the selection when it isn't one of the app's windows).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@601 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-06-12 13:04:15 +00:00
Michael R Sweet
c227a1f369 Fixed drawing bug when min == max...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@599 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-06-12 12:38:14 +00:00
Bill Spitzak
f7c57a3730 Replaced remaining malloc.h's with stdlib.h
Added ctype.h to win32 file
Patch for Fl_Browser_ looping indefinately


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@596 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-06-07 07:03:34 +00:00
Bill Spitzak
1f19505573 Bugfix from Matthias (thanks Matt)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@594 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-25 05:33:56 +00:00
Michael R Sweet
4b341bc95a Added Rick's hack for initializing fl_display.
fl_call_main() and WinMain are now only compiled in for non-GNU compilers
under WIN32 (not needed for Cygwin and friends).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@593 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-24 14:03:47 +00:00
Bill Spitzak
c951750611 Fl_Value_Input did not update if the value was changed from inside the
callback for another Fl_Value_Input.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@592 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-20 18:01:41 +00:00
Michael R Sweet
7fad9c354b Fixed WIN32 selection bug - wasn't checking to see if the
WM_DESTROYCLIPBOARD message from coming from our own
window.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@589 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-15 14:31:32 +00:00
Bill Spitzak
ce68c7386c Colors in cmap changed to use 0xFF instead of 0xF4.
Drawing of scrollbars altered somewhat so that the box (if any) goes
around the buttons, this seems to match the design that other toolkits
use.  Hope everybody likes this...  This required internal changes
to the Fl_Slider and Fl_Value_Slider as well but they should draw
exactly the same.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@587 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-14 09:07:09 +00:00
Bill Spitzak
4e66f93769 Missing header files and FL_EXTERNs that prevented DLL's from compiling
under BCC.
Fluid will output A::B::C names for nested classes.
Fl_Browser::lineposition(n, BOTTOM) will align the bottom of the line
rather than the top with the bottom of the browser.
The connect program does wait() so that it does not leave a zombie for
every one of your ppp connections.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@584 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-11 09:39:31 +00:00
Michael R Sweet
d4bcbf5be3 fl_wait() didn't handle the case when timeout == 0 and nfds > 0.
As a result, you had to wiggle the mouse in order for fds to be
polled on a regular basis.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@583 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-09 14:49:14 +00:00
Michael R Sweet
7f48da7bfd Fixed bug in WIN32 fl_elapsed() function - didn't initialize
prevclock to valid value [now use GetClockTicks()], and
didn't check for newclock < prevclock (which would be
the case if no messages have been processed yet).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@580 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-07 16:17:49 +00:00
Bill Spitzak
c025851f83 Fixed another flwm crash in Fl_x.cxx (the send_motion pointer must
be ignored if the fl_xmousewin is deleted).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@577 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-06 06:20:47 +00:00
Carl E. Thompson
72a313292c Checking in Guillaume Nodet's fix for Fl_Menu_::copy() again. I checked it
in on April 8, but it seems to have disappeared from the CVS.

-Carl


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@574 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-06 01:17:49 +00:00
Michael R Sweet
2f942e1c4a Updated version numbers to 1.0.3.
Fixed browser bug in item_width() - would read past the end of the string
under certain circumstances.

Fixed browser resize bug - wasn't updating bounding box during check, so
it could get in an infinite loop.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@567 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-05-01 15:08:22 +00:00
Michael R Sweet
3f47369dbc Changed $(DSONAME) target to "libfltk.so.1 libfltk.sl.1"...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@560 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-26 12:36:17 +00:00
Bill Spitzak
5bf457ac24 Tab, space, backtab, and backspace can be used to navigate through menus.
They act like up/down arrows except they circulate around at the end.

Fixed a typo in fluid that made it not write when() correctly.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@559 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-26 06:45:29 +00:00
Bill Spitzak
349f047032 Keypad should produce correct symbols on Brazilian (and any other)
keyboard when NumLock is on.  Also added some explanatory comments to
the source code.
Some pointers were not being turned off when widgets were deleted, this
caused flwm to crash.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@553 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-23 06:55:53 +00:00
Bill Spitzak
2f22abf4e2 Compose for Icelandic thorn character is "TH" or "th". Also fixed the
comments in Fl_Input.cxx and fixed the documentation.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@552 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-20 04:43:24 +00:00
Michael R Sweet
df8016354c Updated documentation version & edition.
FLUID makefile referenced LDFLAGS, but we only define CFLAGS and CXXFLAGS.

Fl_Browser::item_height() didn't handle blank lines (returned 2 for the
height).  Also, didn't use textfont() when figuring out text height.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@551 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-19 14:01:23 +00:00
Bill Spitzak
add808d7c2 Changes to Fl_Menu_::add() so that you should be able to add to any menu,
including one that was set with menu().  It copies the static menu if
necessary and keeps track of the size of the menu so it can reallocate
the array exactly when necessary.

This should make modifying the items in a menu much more predictable and
usefule.

I don't know if these changes will go cleanly into 2.0.  Probably not.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@550 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-19 07:01:24 +00:00
Michael R Sweet
816393d2d4 Updated patch version to 2 (1.0.2)
Fixed missing fdsets variable in Fl_win32.cxx

Removed unused maxfd variable in Fl_win32.cxx

FLUID now outputs the window constructor with x,y arguments if
the class name is Fl_Group (this allows you to setup classes
using FLUID)  Add extra code after all the widgets to move them
to the desired offset within the window.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@548 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-18 19:17:03 +00:00
Bill Spitzak
0e29799dda Fl::add_fd() structures are dynamically allocated so you can listen to
as many connections as you want (up to the maximum number handled by
select()).

Fl::remove_fd(fd, when) added.  This allows you to remove the read,
write, and error callbacks individually.  Fl::remove_fd(fd) does
Fl::remove_fd(fd,-1).

Fl::add_fd() calls Fl::remove_fd(), so it can be used safely to
replace callbacks with new ones for the same file descriptor.

Fl::add_timeout() also dynamically allocates it's array so there is no
limit on the number of pending timeouts.

I cut/pasted the changes into the Windoze version but this is
UNTESTED!  Somebody please do a test compile.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@544 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-17 01:02:30 +00:00
Bill Spitzak
fa29bbdc0f 1. ~Fl_Widget(), Fl_Widget::hide(), and Fl_Widget::deactivate() no longer send
FL_LEAVE, FL_RELEASE, or FL_UNFOCUS events to the widget.  This seems to
be desirable behavior and fixes a crash in flwm.
2. After you show() a window, Fl::damage() should be true and remain true
until the window is actually drawn and up to date.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@530 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-10 08:09:39 +00:00
Carl E. Thompson
4605f0f635 Guillaume's fix for Fl_Menu_::copy()
-Carl


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@525 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-08 19:13:02 +00:00
Michael R Sweet
4cb0fad70f Applied Gustavo's WIN32 timer patch to the 1.0.x branch.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@495 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-04-01 14:45:47 +00:00
Carl E. Thompson
81c7d9b215 Changes needed to get FLTK to compile on Borland C++ 5 under Windows. I
compiled this on BC++ 5.0 upgraded to 5.0B via the two monster patches.
I didn't turn on optimization because my version of BC++ doesn't seem to
do much in the way of optimization (FLUID was only 1k smaller when
optimized for size).  VC++ generates smaller code.

The examples that use OpenGL don't work because Borland's linker can't find
"wglShareLists".  I'm sure this is a simple problem, but I don't know how
to fix it.

Borland's C++ compiler won't allow you to call main() from C++, so I had
to add a c function in "fl_call_main.c" to call it so that you don't have
to do that WinMain crap.  However, when I added this file to the Visual C++
project it converted the whole thing from 5.0 format to 6.0 format.  The
files look the nearly identical so I don't think this should be a problem
for 5.0 users, but if it is then you can revert them back to the previous
version and just add this one source file.

Borland really doesn't suck that bad.  It doesn't look as polished as VC++
and it refused to supress some warnings for no reason, but I forgot how
much I liked the feel of Borlands compilers...  Much more intuitive then
MS VC++.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@475 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-29 17:39:46 +00:00
Michael R Sweet
617a7ee619 Makefile didn't clean DSO...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@470 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-26 12:46:25 +00:00
Bill Spitzak
cf2a058806 consistent use of $(LIBRARY) rather than $(LIBNAME)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@468 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-26 07:28:39 +00:00
Michael R Sweet
963f225ab5 Changed hard references to libfltk.a and friends to $(LIBRARY) and
$(DSONAME)...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@466 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-25 22:15:53 +00:00
Michael R Sweet
edab1ef055 Can't use chmod -R on header directory...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@463 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-25 16:09:54 +00:00
Michael R Sweet
08a3198886 Fixed install rule for DSOs - was copying the wrong file...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@460 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-25 15:47:11 +00:00
Michael R Sweet
a5778a1864 Updated README and distribution packages to use v1.0.1.
Updated makefiles and makeincludes to use DSONAME and GLDLIBS.

Updated configure.in to use DSONAME instead of LIBNAME.

Updated editor example code in documentation.

Added ANSI C++ changes to make things compile with the latest EGCS
compiler.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@458 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-25 15:26:44 +00:00
Michael R Sweet
5df541f4f8 Applied Dmitry's timeout patch.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@455 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-25 13:32:52 +00:00
Bill Spitzak
2eafe965c9 Changes from Luis Ibanez to make it compile under Borland.
Includes a real bug that was in Fl_Gl_Window.c (#if WIN32)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@437 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-18 20:04:13 +00:00
Bill Spitzak
4163d5b5ad Added clipping suggested by Dmitry Potapov
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@434 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-16 08:51:02 +00:00
Bill Spitzak
860eda9df2 Clears value() when you clear the menu()
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@433 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-16 08:44:48 +00:00
Bill Spitzak
8b80ea35fe Fixes for os2x by Alexander Mai
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@430 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-15 07:06:46 +00:00
Bill Spitzak
cb3e368539 Fixed alignment of Fl_Choice label with the text in the pop-up menu
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@425 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-13 20:45:20 +00:00
Bill Spitzak
05c916d353 DOH! Fixed even more typos in my fix for Fl_Browser::item_height.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@424 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-13 20:35:33 +00:00
Bill Spitzak
f34388f29a fixed typo that I managed to check in last time...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@423 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-13 20:25:09 +00:00
Bill Spitzak
0f64401722 Fixed Fl_Browser::item_height, I believe this will fix Adrian Miranda's
problems with it.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@422 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-13 20:20:37 +00:00
Bill Spitzak
2316172e5f Fixed fluid bug that caused styles patch to crash when you delete menu item.
Changed a comment in Fl.cxx
Changed valuators demo to remove code to set value() on some widgets and
put the value into the gui box instead.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@421 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-13 20:07:21 +00:00
Carl E. Thompson
fcaa42485f Fix return value of Fl::check(). This fixes the "cube" demo and possibly
other programs.

-Carl


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@420 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-12 19:17:53 +00:00
Michael R Sweet
ce193d0ec5 Fix from Dmitry - wasn't copying data when replacing the text value of a
list item.


git-svn-id: file:///fltk/svn/fltk/trunk@414 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-10 20:06:37 +00:00
Bill Spitzak
b6115887c8 Changes to dial so that counter-clockwise motion is supported if you
set angle2 < angle1.  Deleted the unimplemented direction() control.
Fixed the documentation, this new code allows any 2 values for the
angles as long as abs(a-b)<=360.


git-svn-id: file:///fltk/svn/fltk/trunk@399 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-10 08:17:43 +00:00
Carl E. Thompson
f7e1ff7742 Changes Fl_Dial to use XForms defaults for angles
-Carl


git-svn-id: file:///fltk/svn/fltk/trunk@397 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-10 00:13:52 +00:00
Michael R Sweet
72d1391dbb scandir.c used a variable named "new", which is valid ANSI C but
apparently not accepted by EGCS (EGCS BUG!)...


git-svn-id: file:///fltk/svn/fltk/trunk@396 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-09 20:56:54 +00:00
Michael R Sweet
47e91e6c26 Added libfltk.a to install rules, so both the shared and static libraries
will get installed.


git-svn-id: file:///fltk/svn/fltk/trunk@388 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
1999-03-09 18:33:46 +00:00