Commit Graph

6513 Commits

Author SHA1 Message Date
Manolo Gouy
8feb1bda5f Make all platforms get same kind of Fl_Image object when pasting an image from clipboard.
Previously the X11 platform got an Fl_Shared_Image whereas other got an Fl_RGB_Image,
which made image deletion difficult. Now all platforms get an Fl_RGB_Image object.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11712 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-05-05 07:21:24 +00:00
Albrecht Schlosser
eda47df063 Fix compiler warning when compiled with USING_XCODE [-fpermissive].
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11562 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-04-09 12:38:49 +00:00
Albrecht Schlosser
1bc1f910e0 Improve Unicode documentation, fix typos.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11548 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-04-07 00:01:15 +00:00
Albrecht Schlosser
17f677e0a3 Fix more compiler warnings.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11535 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-04-05 21:12:49 +00:00
Albrecht Schlosser
d2a6ac8b6b Fix compiler warnings found with gcc 4.0.4.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11534 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-04-05 20:35:29 +00:00
Albrecht Schlosser
b4a28580b0 Fix typo.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11532 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-04-05 17:52:04 +00:00
Albrecht Schlosser
a0930b7932 correct typo, format line breaks < 80 columns in README.OSX.txt
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11495 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-04-01 11:10:18 +00:00
Albrecht Schlosser
e8b6b0151a Update example programs to match those of branch-1.3.porting.
This #includes some headers that are #included in FLTK headers.
Although this is strictly not necessary, it removes assumptions that
these header files are included by FLTK headers.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11493 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-31 21:50:34 +00:00
Albrecht Schlosser
11322ede59 Avoid size recalculation if Fl_Browser::textsize() didn't change.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11464 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-29 11:34:10 +00:00
Albrecht Schlosser
474db7e1ff [CMake] Revert r 11460.
Sorry for the noise.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11462 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-29 10:23:45 +00:00
Albrecht Schlosser
c7bf9ce91b [CMake] Fix library name(s).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11460 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-29 09:54:17 +00:00
Albrecht Schlosser
4db4c2910e Fix Fl_Browser::textsize(int) to adjust the scrollbars (STR #3057).
Setting a different text size didn't affect the scrollbars.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11453 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-28 16:16:29 +00:00
Albrecht Schlosser
12d5c63bb8 [CMake] Simplify CMake build files, remove redundancies.
Remove src/fl_call_main.c from non-Windows (static) libraries. It would
be an empty object file anyway.

Use CMake variables to set up used files and linked libraries to remove
redundancies. All files and libs are used only in the definition of
CMake variables and used later in static and shared builds, resp.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11444 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-27 18:30:51 +00:00
Albrecht Schlosser
448e02574b [CMake] Remove redundant linking in CMake build process (STR #3298).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11442 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-27 16:56:23 +00:00
Albrecht Schlosser
16e1d9db41 [CMake] Fix library name (Debug mode), add fluid dependencies.
The library name in Debug mode must only be 'libname'd.a if the build
is with MSVC; all other builds never appended the 'd' suffix to the name.
This is also documented (see lib/README).

Fluid did not regenerate the .cxx and .h files if the .fl file was changed.
The DEPENDS keyword adds the necessary dependency.
The MAIN_DEPENDENCY keyword "also suggests to Visual Studio generators
where to hang the custom command" according to CMake docs.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11430 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-26 14:20:32 +00:00
Albrecht Schlosser
3356a15d18 Fix compiler warning.
Back-porting from branch-1.3-porting.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11423 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-25 20:55:13 +00:00
Albrecht Schlosser
de74c82d42 Enable definition of Unicode conv. options on compiler command line.
Three documented pre-processor variables can now be defined on the
compiler command line to avoid editing the FLTK src code. The default
values still apply unchanged.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11404 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-23 13:36:50 +00:00
Albrecht Schlosser
4bfabbd619 Update minimum required CMake version to 2.6.3.
Verified build with CMake 2.6.3, failed with 2.6.2.

We need 2.6.3 for "unset" (unknown command in 2.6.2 and earlier).

CMake 2.6.2 also fails when parsing nested brackets in logical
expressions like the following one:

  if((NOT APPLE OR OPTION_APPLE_X11) AND NOT WIN32)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11396 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-22 00:08:26 +00:00
Albrecht Schlosser
612e6d7974 Fix Doxygen warning.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11390 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-20 17:55:17 +00:00
Manolo Gouy
014ea2f871 Fix potential memory error in Mac OS code for printing window titlebars.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11370 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-19 06:04:19 +00:00
Manolo Gouy
71ed0752fb Fix minor default in Fl_Window::wait_for_expose() under Mac OS.
If the exposed window contains a sub-window the sub-window can disappear
after having been drawn. This can be seen with the device demo
completed with a wait_for_expose() call just after the main window show().
The fix applies wait_for_expose() recursively for all subwindows.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11352 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-12 05:35:40 +00:00
Manolo Gouy
a0f26d3cf4 Fix freeze of Fl_Native_File_Chooser occurring under Mac OS + X11.
The fclose(stderr) apparently freezes the opening of the GTK file chooser.
It is replaced by 2>&- which closes stderr for the lpstat command.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11329 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-09 16:08:39 +00:00
Albrecht Schlosser
a9b052b038 Update CHANGES.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11322 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-08 17:05:50 +00:00
Albrecht Schlosser
a0d519142c Add localization of modifier key names in shortcut labels.
Modifier key names like Alt, Shift, Ctrl, Meta can now be localized by
setting global string pointers. See documentation of fl_shortcut_label().


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11321 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-08 16:58:43 +00:00
Albrecht Schlosser
15477700ed Improve documentation of Fl_Valuator class.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11316 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-08 13:42:59 +00:00
Albrecht Schlosser
6f18ec06d5 Fix overflow in Fl_Valuator::precision(int) to 0...9 (STR #3280).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11315 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-08 13:40:18 +00:00
Ian MacArthur
337e115c54 Fl_Tree failed to compile if built with no ABI guard set (or the default 1.3.0 set).
The variable "_lastselect" had been added to the methods Fl_Tree::remove() and Fl_Tree::clear() without any ABI guards, but "_lastselect" was added to the class ABI at 10301 (so far as I can tell).

Builds now with my patch: not sure it is correct, but... Will commit anyway since it allows the lib to build, but please feel free to fix it better!




git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11314 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-08 09:56:46 +00:00
Manolo Gouy
d01ff3864f With X11 + Xdbe, deallocate the Fl_Double_Window's back buffer at window close.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11312 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-08 05:18:28 +00:00
Greg Ercolano
c9e114945e lastselect_: reset to zero in remove() + clear(), added description comment for variable.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11306 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-07 20:35:28 +00:00
Albrecht Schlosser
0d316c3140 Remove obsolete files.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11295 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-05 16:24:37 +00:00
Albrecht Schlosser
4b63361471 Fix and simplify exe name handling in demo (Windows).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11293 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-05 14:38:35 +00:00
Albrecht Schlosser
a3457f745c [CMake] Mark OPTION_USE_POLL as advanced.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11291 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-05 13:29:18 +00:00
Albrecht Schlosser
08d4044829 Add Ian's offscreen test program.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11287 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-05 00:39:40 +00:00
Albrecht Schlosser
3948405951 Fix negative 'd' and 'ld' args in fl_draw_image() (X11 + Windows).
This commit fixes a regression in FLTK 1.3.x, where negative values
of 'd' (pixel delta) and 'ld' (line delta) didn't work anymore under
Unix/Linux (X11) and Windows.

With this commit the regression is fixed on all supported platforms.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11270 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-02 15:45:26 +00:00
Albrecht Schlosser
59aa9b25d6 Enable negative 'd' and 'ld' arguments in fl_draw_image() test.
This commit defines additional preprocessor macros to enable testing
negative d and ld arguments of fl_draw_image(). Documentation (test
scenario) has also been improved.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11269 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-02 15:38:18 +00:00
Albrecht Schlosser
e4f26ea33a Don't expose X11 headers in user space any more (mostly).
Platform headers should not be #include'd in public FLTK header files,
so that user space is not polluted by platform specific definitions.

This commit fixes FL/fl_utf8.h to #include X11 headers only if compiled
in the FLTK library.

Todo (FLTK 1.4): Remove more unnecessary (unwanted) system header #include
statements from FL/x.H and other public header files.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11266 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-02 12:15:08 +00:00
Manolo Gouy
25b6e93c44 Mention fix for fl_draw_image() on the Mac.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11264 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-02 08:00:41 +00:00
Manolo Gouy
35010115c9 Allow fl_draw_image(buf,X,Y,W,H,D,L) calls with abs(L)>D*W on the Mac OS platform.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11263 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-02 07:51:53 +00:00
Manolo Gouy
f4cc803b3c Have fl_draw_image(buf,X,Y,W,H,D,L) support negative D and/or L arguments on Mac OS X - continued.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11254 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-01 15:08:57 +00:00
Manolo Gouy
de07c2ea94 Accept fl_draw_image(buf, X,Y,W,H,D,L) with negative D and/or L arguments on the Mac OS platform.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11250 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-29 17:01:01 +00:00
Albrecht Schlosser
8922a226d8 Update CHANGES (compiler warnings, STR #2988).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11247 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-27 17:39:29 +00:00
Albrecht Schlosser
024f60fd4f Fix copyright year again (sorry for the noise).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11245 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-27 15:51:09 +00:00
Albrecht Schlosser
d22f87ca3b Fix fluid/Makefile again.
The previous commit unintentionally reverted the patch before that.
Also remove duplicate from target clean.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11244 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-27 15:43:26 +00:00
Albrecht Schlosser
753aa53c2e Fix compiler warnings, last part (STR #2988).
The fixes in this commit include those proposed in file #6
(fltk-misc-1.patch) with a few modifications (see comment on STR).

Changes in src/fl_set_font.cxx are not included (see comment #13).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11243 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-27 15:14:42 +00:00
Albrecht Schlosser
c33f143710 Fix fluid/Makefile: add *.bak to target "clean".
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11240 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-27 02:09:39 +00:00
Albrecht Schlosser
4c191cda8f Update dependencies.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11211 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-22 17:46:53 +00:00
Albrecht Schlosser
78dad08926 Fix unused variable compiler warning.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11210 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-22 17:38:26 +00:00
Albrecht Schlosser
7d3eaf31c2 Update CHANGES.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11206 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-22 17:11:02 +00:00
Albrecht Schlosser
21da7922d0 Fix slow scrolling, line number display, and scrollbars (STR #3272).
Optimized wrap mode - removed unnecessary wrap margin calculations.
The speed-up is significant, but there is still room for improvements.

Refactored parts of the code to make the decisions more modular and
(hopefully) obvious.

This commit also fixes some positioning issues with different scrollbar
alignments and the new line number display.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11205 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-22 16:41:55 +00:00
Albrecht Schlosser
a72bba7a3c Add some test options to test/editor.cxx.
These options are not enabled by default, but you can enable them by
defining macro DEV_TEST. This adds buttons to toggle wrap mode,
scrollbar positions, and to increase or decrease the window size (width).

Note: this can be used to test STR #3272 and the fixes in a follow-up
commit.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@11204 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-22 16:36:38 +00:00