Commit Graph

2655 Commits

Author SHA1 Message Date
Manolo Gouy
c64fa4863e Added info about where to find Mac OS virtual keycodes.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8545 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-29 14:22:48 +00:00
Manolo Gouy
5cda7e7232 Set svn properties.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8544 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-29 11:19:51 +00:00
Manolo Gouy
d4f284d73c Minor change.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8543 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-29 08:39:40 +00:00
Manolo Gouy
c4e554ff6b Mac OS: simplified the handling of text input:
use the FLTextView subclass of NSTextView only for Mac OS < 10.5 because it's not
necessary for Mac OS >= 10.5

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8542 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-28 21:52:56 +00:00
Manolo Gouy
c6fb27e56d Mac OS: added field subwindow to Fl_X class that is true if this is a subwindow.
Useful when deleting a window because subwindows share their xid with their parent
window (unlike under MSWIn or Xlib), so subwindows should not delete their xid.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8540 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-28 09:28:05 +00:00
Albrecht Schlosser
409d4976c2 Enhanced documentation of Fl::event_inside() to mention the restrictions
WRT subwindows and when using the window itself as the widget argument.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8538 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-27 00:34:55 +00:00
Manolo Gouy
8d7c246676 Mac OS: added gl_texture_reset() function to be called when deleting an Fl_Gl_Window
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8537 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-26 21:56:24 +00:00
Manolo Gouy
a58a2ed9fb Mac OS: Fixed bug where gl_draw() would fail after deletion of an Fl_GL_Window.
The fix invalidates the pile of string textures after each Fl_Gl_Window deletion.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8536 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-26 14:37:28 +00:00
Manolo Gouy
3b7ff83e04 Fix STR #2595. Mac OS. When deleting a subwindow, don't delete the Cocoa window
(xid) attached to it because it is in fact the Cocoa window of its parent window.
I check that by making sure that none of the windows in the window list uses
this Cocoa window. Is there a better algorithm ?

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8534 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-25 23:17:16 +00:00
Manolo Gouy
f088e583a1 Fix 2nd issue of STR #2594: Fl::focus() now informs Mac OS when the focus
changes window.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8533 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-25 12:31:51 +00:00
Manolo Gouy
f8b645f614 Fl::focus(): allows the focus to be set to an Fl_Window widget.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8532 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-25 12:16:57 +00:00
Manolo Gouy
edd848aa9c Mac OS: implement the Cocoa equivalent of Carbon's kEventWindowHidden handler.
Positive effect visible with the clock demo.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8531 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-25 12:02:31 +00:00
Manolo Gouy
9fa8427b78 Fix STR #2594: the focus after creating a new window was not set correctly
because some code present in Fl_mac.cxx was not reflected in Fl_cocoa.mm.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8530 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-24 12:58:32 +00:00
Manolo Gouy
1366cc68d3 PostScript support: simplified the Fl_PostScript_Graphics_Driver class by removing the
draw_scaled_image(_mono)() member functions.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8528 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-22 17:41:23 +00:00
Manolo Gouy
16d983eab4 Mac OS: correct handling of fl_draw_image() call with L > W*D when printing.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8527 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-22 17:14:37 +00:00
Manolo Gouy
dfc067ecfc Fix STR #2587: under Xlib, the X input method must be reset by the Fl::compose_reset() function.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8522 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-21 16:32:37 +00:00
Manolo Gouy
a36bca971a Fix STR #2589: incorrect cohabitation of modal and non-modal windows.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8521 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-20 21:43:10 +00:00
Manolo Gouy
7aa48e19b9 Fix STR #2575: use the screen that intersects most of the window when made fullscreen.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8515 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-12 21:36:21 +00:00
Manolo Gouy
1d038565c1 Mac OS: modified the definition of the fl_mac_os_version global variable to allow v 10.10.10
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8504 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-04 16:48:10 +00:00
Manolo Gouy
23ac5868eb Changed copyright year to 2011
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8499 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-02 14:17:34 +00:00
Manolo Gouy
f22e50af97 STR 2580: the first Fl::add_timeout() call now calls fl_open_display() because that is necessary for
timeout events to be recovered by the event loop. 

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8489 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-01 12:37:34 +00:00
Manolo Gouy
f7d7eff7ad STR 2580: Fl::add_fd() now calls fl_open_display() because that is necessary for the fd event
to be recovered by the event loop. Before main() is called, only fl_mac_os_version is 
initialized.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8488 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-01 11:58:36 +00:00
Manolo Gouy
8c9d34facf The got_events global variable is now updated when an event is processed by do_queued_events
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8486 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-28 17:48:55 +00:00
Albrecht Schlosser
58c94b9b33 Suppress warnings in fl_init_xim. Only the very first warning message
will be issued (STR #2578).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8478 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-26 14:14:50 +00:00
Albrecht Schlosser
d98a0fede6 Removed extraneous '\n' from Fl::warning() calls in src/Fl_x.cxx.
Note: '\n' is added in the default Fl::warning() handler function and should
not be in the format string.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8473 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-25 09:15:57 +00:00
Albrecht Schlosser
94e5f2e1fc Un-inlined Fl_Window::icon() methods to make them easier to extend w/o
breaking the ABI. See discussion in STR #2563.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8472 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-25 08:44:47 +00:00
Manolo Gouy
27987c6ee0 Made struct matrix a subclass of Fl_Graphics_Device class to avoid collision
with application-defined names.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8471 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-24 18:02:11 +00:00
Manolo Gouy
278c821ff4 Mac OS only: allows to print a menu window.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8470 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-24 16:58:00 +00:00
Manolo Gouy
d8822aa74a Fl_Device: removed class_name(char *) member function and set class_name(void) virtual.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8467 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-23 14:36:18 +00:00
Manolo Gouy
5a6da14af3 Fl_Text_Display: avoid blinking by painting the full widget background only to the printer.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8466 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-23 11:47:51 +00:00
Manolo Gouy
6d38eb67bc Fl_Text_Display widget: added a call to paint all the widget area with its background color
when it's fully redrawn, to avoid thin grey lines that appear when this widget is printed.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8463 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-22 17:50:25 +00:00
Manolo Gouy
6e24f93c1a Corrected typos.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8462 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-22 09:41:26 +00:00
Fabien Costantini
cc79642a94 Say goodbye to weird comctl32.lib link clause in vc20xx builds. Now embeds it if it is supported, so no need to specify more than fltk libs in new fltk projects ! Makes it similar to other platforms linkage options and will probably improve learning curve of fltk new users. Improvements could be implemented for even easier/transparent linkage (fltk libs, fltk dlls?) of fltk apps.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8461 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-21 18:33:46 +00:00
Manolo Gouy
a998c478d5 Removed inadequate use of fl_color() function.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8459 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-21 14:05:51 +00:00
Manolo Gouy
693d12ee88 Better horizontal positioning of right-to-left text.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8458 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-21 13:39:08 +00:00
Manolo Gouy
287f5684ee Fix STR #2569 cont'd: put back MSWindows version of Fl_Native_File_Chooser::filters()
that had been erroneously removed by r.8378 that merged include files (it was
previously an inline function).

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8454 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-20 21:46:11 +00:00
Manolo Gouy
c8ae58db48 Fix STR #2569: put back Mac OS version of Fl_Native_File_Chooser::filter_value() and filters()
that had been erroneously removed by r.8378 that merged include files (these were
previously inline functions for Mac OS only).

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8453 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-20 21:28:55 +00:00
Manolo Gouy
ea3e3dae9b Fl::set_fonts() under Mac OS: it seems that we want the full name rather than the PostScript
name for each font.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8452 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-20 08:25:26 +00:00
Manolo Gouy
f18ac86bee Fl::set_fonts() under Mac OS: added missing delete statement.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8451 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-20 08:02:50 +00:00
Greg Ercolano
5bbcebe9cd Small mod for NULL behavior of show_item(item,yoff). (STR#2517)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8450 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-19 22:50:39 +00:00
Greg Ercolano
723fe666cf Document NULL item behavior, small code mods for same.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8449 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-19 22:40:31 +00:00
Manolo Gouy
3ca2074427 Fl::set_fonts() under Mac OS adds now all available fonts sorted in alphabetical order.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8447 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-19 22:29:39 +00:00
Manolo Gouy
601e2a5e3d Fix STR #2564: X11 preferred font encoding should now be iso10646-1.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8446 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-19 18:03:43 +00:00
Manolo Gouy
ece0c2a57b Fixed Fl_PostScript_Graphics_Driver::rtl_draw() that didn't work well under MSWindows.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8445 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-19 13:01:45 +00:00
Manolo Gouy
cbaecee14e Minor improvement of the Fl_Graphics_Driver::text_extents() function used only if
a graphics driver does not properly implement text extents calculation.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8444 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-19 07:36:29 +00:00
Manolo Gouy
f5f0cf9908 Added scale(), translate(), and rotate() functions to the Fl_Graphics_Driver class.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8443 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-18 17:22:43 +00:00
Manolo Gouy
199b32d921 Added virtual width(), height(), descent() and text_extents() functions to the Fl_Graphics_Driver
class to prepare for the future definition of graphics drivers that fully deal with text measurement.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8442 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-18 13:39:48 +00:00
Albrecht Schlosser
2c129b4833 Added a default window title function for common dialogs (STR #2562).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8441 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-18 08:52:48 +00:00
Manolo Gouy
dea2763983 Fix STR #2566: under Xft, the PostScript font size is set at value between the FLTK size
and the Xft-reported font height.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8440 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-17 14:29:44 +00:00
Manolo Gouy
162895ad57 Improved calculation of text width and height when using the PostScript graphics context
under Mac OS and MSWindows.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8438 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-02-16 15:17:01 +00:00