Commit Graph

96 Commits

Author SHA1 Message Date
Michael R Sweet
dc7a14aa9a Rework event loop handling on all platforms for better timer and idle
processing (STR #861)



git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4589 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-10-12 20:19:30 +00:00
Matthias Melcher
820b67bc56 This change will make sure that top-level windows will fit inside the screen that contains the original x and y.
The previous version would reposition windows in the screen that currently contains the mouse. That feature made it impossible to position tool windows on a second monitor, etc. . 

This change does not affect popup windows which will still pop up in the screen that has the mouse pointer.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4559 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-09-09 09:52:16 +00:00
Matthias Melcher
fc8b075951 On X11, borderless windows will not show in the taskbar anymore (STR #933)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4492 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-08-08 23:31:41 +00:00
Michael R Sweet
fc4db19395 Don't make non-inline methods from FLUID inline (that is, remove the
"inline" from non-inline methods...)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4285 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-04-15 18:00:33 +00:00
Michael R Sweet
782abe6de6 Added MacOS X monitor support.
Now use new screen_xywh() API for keeping things on the current screen.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4227 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-03-31 20:31:39 +00:00
Michael R Sweet
add37faa25 Copyright updates.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4052 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-02-24 21:55:12 +00:00
Michael R Sweet
e4ccb4ac07 Fix X11 DND support.
src/Fl_x.cxx:
    - Check the list of source types and pick the first one that
      starts with "text/".


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3995 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-02-01 03:13:01 +00:00
Michael R Sweet
b5562132e5 Fl::event_number() didn't always match the value sent to the
handle() method (STR #634)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3930 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-12-03 03:14:17 +00:00
Michael R Sweet
7a2e635a8e Fix a resize() bug...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3901 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-11-20 13:52:47 +00:00
Michael R Sweet
64f0dbc2a5 - FLTK windows could appear off-screen on X11 (STR #586)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3899 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-11-20 04:18:44 +00:00
Michael R Sweet
421904a7c1 Fixed problems with 2-byte Xpm files on 64-bit platforms (STR
#525)

FLTK didn't handle the ReparentNotify event on X11 (STR #524)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3819 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-09-11 19:32:43 +00:00
Michael R Sweet
ca116a1b6c FLTK now honors the numlock key state (STR #369)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3429 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-06-01 01:08:50 +00:00
Michael R Sweet
848f54d636 Doco changes.
Start of fixes for word wrap + proportional text.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3425 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-05-24 01:30:45 +00:00
Michael R Sweet
998f74be9f Fl_Scroll now uses a full redraw when the scheme is set to
plastic and the box type is a frame (STR #205)

Fl_Window::resize() did not work properly with KDE 3.2 (STR
#356)

FLTK didn't delete font bitmaps when the last OpenGL window was
deleted, preventing future text from displaying (STR #310)

FLUID didn't include a full initialization record for the
trailing NULL menu items (STR #375)

Fl_Browser::item_width() did not properly handle format
modifiers (STR #372)

Fl_Browser::item_height() did not handle columns properly (STR
#371)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3419 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-05-15 22:58:19 +00:00
Michael R Sweet
e643c17eea Fl_Gl_Window's on WIN32 now prefer accelerated pixel formats
over generic formats (STR #382)

Fl_Window::resize() did not work on some systems if the window
was not shown (STR #373)

FLUID did not write the user_data type if the user_data field
was empty (STR #374)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3416 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-05-13 21:02:41 +00:00
Michael R Sweet
a3d0905c9e Copyright updates and prep for 1.1.5rc1.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3391 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-04-11 04:39:01 +00:00
Michael R Sweet
6d84fa98b7 Fix CTRL+something "-" - wasn't tracking the proper CTRL key
state (STR #264)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3215 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-02-29 22:16:11 +00:00
Michael R Sweet
1b84038345 WIN32's scandir() emulation did not allocate enough memory for
directory names (STR #263)

Fl::compose() did not handle special keys like backspace
properly (STR #293)

Fl_Choice did not clip its text when drawing using the plastic
scheme (STR #287)

Fl_Group incorrectly mapped the emacs CTRL keys to keyboard
navigation (STR #228)

Fl_File_Browser::load() didn't handle a NULL directory name (STR
#266)

64-bit library fixes (STR #261, )

The Fl_Valuator::format() function did not limit the size of the
number buffer (STR #268)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3211 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-02-26 03:06:41 +00:00
Michael R Sweet
7f15f8d97f Make sure Fl::event_text() is not NULL. (STR #70)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3030 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2003-06-15 04:27:35 +00:00
Michael R Sweet
13005b2a3f Fl_File_Browser incorrectly included "." on WIN32 (STR #9)
Include shellapi.h instead of ShellAPI.h in the WIN32
drag-n-drop code in order to work with the MingW cross compiler
(STR #6)

The cursor was not properly restored when doing drag-n-drop on
X11 (STR #4)

Fl::remove_fd() didn't recalculate the highest file descriptor
properly (STR #20)

Fl_Preferences::deleteGroup() didn't work properly (STR #13)

Fixed the fl_show_file_selector() function - it was copying
using the wrong string size (STR #14)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2975 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2003-05-04 21:45:46 +00:00
Matthias Melcher
7903799bf2 - sorted fluid menu bar
- fixed some minor Valgrind memory checker complaints
- added conditional compile flag for OS X w/ MetroWerks compiler


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2967 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2003-04-03 04:28:15 +00:00
Bill Spitzak
32c831857a Backport of FL_LEAVE fix from 2.0. Belowmouse would go to zero when
mouse moved from one window to another belonging to the app.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2949 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2003-03-09 02:00:06 +00:00
Michael R Sweet
d602263b78 FL_KEYUP patch for X11 - don't send KEYUP event for repeating keys.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2937 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2003-01-31 15:50:28 +00:00
Michael R Sweet
00cb676e11 Copyright update for 1.1.3 release (not quite yet, but soon...)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2936 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2003-01-30 21:46:07 +00:00
Michael R Sweet
82eeab48e6 Initialize backbuffer_bad under X11.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2680 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-10-20 06:06:31 +00:00
Michael R Sweet
050919103f More shadow variable changes...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2567 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-08-09 03:17:30 +00:00
Michael R Sweet
bb056f7805 Update GCC test in configure script.
Add range checking to BMP loader, and fix colormap + 4-bit BMP file
loading.

Copy 2.0 window position fix for XFree86 4.x and others.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2315 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-06-24 02:04:54 +00:00
Michael R Sweet
acd6bd5cc8 Clean up string includes.
Fix Fl_Shared_Image::add_handler() and friends.

Fix Fl_PNM_Image loader.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2260 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-05-25 13:38:25 +00:00
Michael R Sweet
fc7facb5e9 Changelog and cleanup.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2251 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-05-23 16:47:41 +00:00
Michael R Sweet
7482426735 Make Fl_Output a subclass of Fl_Input, and add input_type and readonly
methods/constants to support Fl_Output as a special case of Fl_Input
(you can do everything but change the text in Fl_Output...)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2073 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-04-11 11:52:43 +00:00
Michael R Sweet
a84320659b Fix enter/leave on windows to properly handle tooltip focus...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2064 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-04-10 01:32:03 +00:00
Michael R Sweet
6fa4abfe54 Fix NULL argument to fl_filename_name()...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2056 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-04-07 18:31:55 +00:00
Michael R Sweet
fdf2e2e690 Make all implementations of cut/paste/dnd consistent with global
fl_selection_xyz state vars...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2038 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-03-26 17:37:42 +00:00
Michael R Sweet
6c796f88c7 Rename all remaining functions that don't start with fl_ to
fl_foo. (filename_xyz becomes fl_filename_xyz, down becomes
fl_down, define_FL_PLASTIC_BOX becomes fl_define_FL_PLASTIC_BOX,
etc.)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2026 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-03-25 21:08:42 +00:00
Michael R Sweet
ba2eae871a Wasn't enabling XDND...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2011 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-03-25 02:36:59 +00:00
Bill Spitzak
5f55e1cd63 Back-ported cut & paste code from fltk2.0.
This code splits the cut & paste into two buffers. The "SELECTION" is
used for the currently highlighted text and for middle-mouse paste and
(if possible) for handling drag & drop. The "CLIPBOARD" is for Ctrl+C
and Ctrl+V style cut & paste.

This matches how Motif, GTK, and KDE 3.0 work. But many older X
applications (including KDE 2) can only see SELECTION, this results in
cut & paste incompatability that is familiar to X users. However this
now moves fltk over to the majority camp.  On all systems this
eliminates the annoying inability to select a region and replace it
with Ctrl+V.

On Mac and Win32 the SELECTION is local to the application, so
middle-mouse paste only works between fields in the application. There
may be tricks (special clipboard data types? use drag & drop?) to make
it communicate, but unless there are standards it would be fltk-only.

The file Fl_cutpaste.cxx has been deleted, so update the IDE files!
The Win32 and Mac versions have NOT BEEN TESTED! I tried to be careful
editing them but they may need some work.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1989 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-03-07 19:22:58 +00:00
Michael R Sweet
be3181a39a Use "1" instead of "true" for return value (true not available on all
C++ compilers...)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1964 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-02-19 20:21:10 +00:00
Michael R Sweet
6eff9b3b14 First round of DND additions to 1.1 - just X11 code, and I haven't added
the support in widgets yet.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1925 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-01-09 21:50:02 +00:00
Michael R Sweet
8fe611b5cd Fix changing of schemes - otherwise Fl_Window::show() could cause a
reference to a non-existing tiled image.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1908 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-01-03 18:28:37 +00:00
Michael R Sweet
64b4177ef4 Copyright updates...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1903 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-01-01 15:11:33 +00:00
Michael R Sweet
ba2be02ab2 FLTK 2.0 threading support under FLTK 1.1. Needs porting to OSX.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1819 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-12-06 22:16:49 +00:00
Michael R Sweet
2b85bf8168 Preliminary commit of my MacOS X work.
**** THIS CODE COMPILES BUT DOES NOT WORK. ****

TODO: fix event handling - getting blank windows, etc.
TODO: re-port OpenGL code.
TODO: add support for images with alpha.
TODO: add support for more then just beeps in fl_beep().
TODO: other stuff I'm sure...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1765 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-11-27 17:44:08 +00:00
Michael R Sweet
f525840495 Fix all references to '.C' files (now .cxx)
Update Fl_Image() class to track depth and data, so FLUID will be
able to use it as the base class.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1712 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-11-22 15:35:02 +00:00
Michael R Sweet
fb4fe5642a Don't send FL_RELEASE events for buttons 4 and 5 (mouse wheel)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1704 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-11-19 18:28:55 +00:00
Michael R Sweet
831d7cde5b FL_KEYUP event support.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1661 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-10-27 03:45:29 +00:00
Michael R Sweet
9da85233f9 Fl::belowmouse() was resetting the tooltip, causing the flashing
in the FLUID window and havoc for the KDE 2.2 window manager...

Changed the default tooltip position to be +10, +10 from the
mouse pointer, and the default tooltip background color to a
pale yellow to match other toolkit defaults.

Update Fl_Widget::flags_ to be an integer, to support more flag
bits.

Update Fl_Window to support override() and set_override() methods.

The configure script did not set the default library path to
/usr/lib32 under IRIX 6.2 and higher when prefix is /usr.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1637 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-10-18 18:53:20 +00:00
Michael R Sweet
85533d11be Fix mouse wheel stuff for browser and helpview widgets (move 3 lines at
a time...)

Fl_Group::handle() now sends unknown events to the focus widget first,
then to any other child that will take it...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1542 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-08-02 21:11:43 +00:00
Michael R Sweet
2d3fd88eeb More mouse wheel stuff (as compatible as possible with the 2.0 code...)
Updated the makefile to use config.status --recheck before calling
config.status (why they can't provide one that does both, I don't
know...)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1540 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-08-02 20:09:25 +00:00
Michael R Sweet
ff3295f036 Handle WM_ACTIVATEAPP message under WIN32, using GetAsyncKeyState() for
all of the key and button states in FLTK.

SunOS 4.x changes (check for <sys/stdtypes.h> and don't rely on
realloc(NULL, size) working - this doesn't work on a lot of platforms!)

Fix nesting of #ifdefs in vsnprintf.c - the C++ wrapper stuff wasn't
being included outside the checks for the individual functions...


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@1444 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-04-27 14:39:27 +00:00
Michael R Sweet
94788c4628 Copyright 2001.
FLTK 1.0.11.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@1356 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-01-22 15:13:41 +00:00