Commit Graph

7335 Commits

Author SHA1 Message Date
Albrecht Schlosser
a21f16486a Fl_Text_Display documentation updates.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12168 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-02-01 18:36:23 +00:00
Manolo Gouy
e7356529bb Allow ESC to close window and don't transmit CTRL character to fl_draw()
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12167 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-26 08:13:19 +00:00
Manolo Gouy
782d34fc8f MacOS: reduce the memory size of class gl_texture_fifo managing GL textures to draw strings under GL.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12166 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-24 12:53:33 +00:00
Manolo Gouy
c8fc8cc241 Allow resizable Fl_Gl_Window drawn using the Fl_OpenGL_Graphics_Driver
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12165 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-20 17:18:38 +00:00
Manolo Gouy
898d2580d3 Remove USE_OksiD_style_GL_font_selection preprocessor variable because it is equivalent to !USE_XFT
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12164 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-19 09:38:12 +00:00
Manolo Gouy
ebae29222d Fl_OpenGL_Graphics_Driver : use gl_font()/gl_draw() to draw text in a GL window - continued.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12163 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-10 17:21:14 +00:00
Manolo Gouy
723012c2bd Fl_OpenGL_Graphics_Driver : use gl_font()/gl_draw() to draw text in a GL window.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12162 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-10 15:33:14 +00:00
Manolo Gouy
0e22ca28dd Match glPushAttrib() with glPopAttrib()
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12161 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-10 15:12:42 +00:00
Manolo Gouy
28f1bdd408 Remove useless #include directives
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12160 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-10 10:23:19 +00:00
Manolo Gouy
d589dcd127 Correct spelling error: Armeninian --> Armenian
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12159 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-08 17:35:52 +00:00
Albrecht Schlosser
69353b5b11 Add "lorem ipsum" text file in different languages and scripts.
This file can be used to test pango integration and potentially later
also right-to-left text editing which is currently not supported.

The image misc/lorem_ipsum.txt shows lorem_ipsum.txt in test/editor
built with pango under Linux (Ubuntu 14.04 LTS).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12158 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-06 13:47:51 +00:00
Manolo Gouy
06924c37cb Add implementation explanatory comments about how the screen driver supports public function fl_read_image().
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12157 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-04 07:44:31 +00:00
Manolo Gouy
06b98099f9 Documentation: drawing a scaled shared image no longer involves resizing the source image under MSWindows.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12156 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-01-02 09:48:23 +00:00
Albrecht Schlosser
3145e06585 Fix CMake config.h and compiler warnings.
Fixed warnings: -Wsign-compare, -Wunused-but-set-variable.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12155 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-23 15:40:25 +00:00
Albrecht Schlosser
60a9eee30d Fix inverted configure logic for option --enable-print.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12154 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-23 15:34:39 +00:00
Manolo Gouy
461750c38e X11 platform: Add optional use of the pango library to draw text, gaining the possibility to draw text in any script supported by Unicode.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12153 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-21 15:05:02 +00:00
Manolo Gouy
00ebcd23aa Fix Fl_Xlib_Graphics_Driver::delete_bitmask() : the pixmap argument is to be deleted by XFreePixmap().
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12152 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-21 14:52:16 +00:00
Greg Ercolano
87f339249a Fix for Brain Davis' bug report in fltk.general on 12/20/16.
Subject: Fl_Glut_Window::Fl_Glut_Window(int w, int h, const char *title = 0)... err huh well no, but it should be



git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12151 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-20 23:27:29 +00:00
Manolo Gouy
5a7f80c466 When targetting MacOS+X11, fltk-config should not bundle the executable.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12150 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-19 14:35:08 +00:00
Manolo Gouy
936486cb1c Handle non-ASCII characters when selecting a word or moving the cursor by one word.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12149 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-17 07:42:54 +00:00
Manolo Gouy
d0f6ef5d32 Improve Fl_Graphics_Driver::copy_offscreen() so it accepts an Fl_Offscreen argument even if not created by fl_create_offscreen().
With this, fl_copy_offscreen() can be used with any drawing surface (e.g., PostScript) and any Fl_Offscreen
argument (e.g., returned by Fl_image_Surface::offscreen()).

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12148 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-16 16:06:07 +00:00
Manolo Gouy
1fc01c7cbb Implement a platform-independent version of Fl_Graphics_Driver::copy_offscreen() usable when drawing to PostScript.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12147 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-14 18:54:12 +00:00
Manolo Gouy
6645a6b225 It is better to reset the line width after having finished to draw with a modified width.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12146 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-14 18:38:01 +00:00
Albrecht Schlosser
843aba4c68 Fix compiler warning [-Wsign-compare].
warning: comparison between signed and unsigned integer expressions


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12145 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-12 20:50:16 +00:00
Manolo Gouy
d17f17e606 The virtual function Fl_Graphics_Driver::copy_offscreen() cannot be implemented in a platform-independent way.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12144 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-12 18:20:26 +00:00
Manolo Gouy
d37f37e66e Mention Fl_Surface_Device::push_current(new_surface) and Fl_Surface_Device::pop_current().
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12143 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-10 14:40:00 +00:00
Manolo Gouy
c33df704ab Doxygen: more detailed descriptions of Fl_Image_Surface::offscreen() and Fl_Image_Surface::get_offscreen_before_delete().
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12142 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-09 18:07:08 +00:00
Manolo Gouy
40f977ccce Simpler code path for a member function calling another member function of same class.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12141 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-09 09:48:56 +00:00
Manolo Gouy
43935dffeb Add static void Fl_Surface_Device::push_current(Fl_Surface_Device *new_current) and pop_current() to set/unset the current drawing surface.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12140 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-07 15:09:52 +00:00
Matthias Melcher
0a1eed150a Fixed OS X SDL double buffering issue and mouse dragging.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12139 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-06 23:21:52 +00:00
Albrecht Schlosser
307dd033f0 [CMake] Rewrite pthreads checks for compatibility with configure.
Main point: pthreads must not be checked under Windows (e.g. MinGW)
since Windows always uses native Windows threads (unless Cygwin is used).


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12138 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-06 19:20:34 +00:00
Albrecht Schlosser
da816dff5d Fix building without threads (pthreads).
Note: 'configure --disable-threads' or 'cmake -DOPTION_USE_THREADS=OFF'.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12137 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-06 18:49:22 +00:00
Ian MacArthur
b3c97970f3 For consistency, make the pre-processor check for the inclusion of "dlfcn.h" be
the same as the check which is subsequently used before calling dlsym() and dlopen().

Note that this may also work around an occasional issue observed when building
for Windows with cmake and mingw-64, which was sometimes erroneously attempting
to #include "dlfcn.h" - which is not generally appropriate on a Windows host.



git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12136 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-05 22:06:56 +00:00
Albrecht Schlosser
780755e46a Fl_Text_Display documentation clarifications.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12135 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-05 17:47:02 +00:00
Albrecht Schlosser
b6bd386231 Fl_Text_Buffer constructor: fix "requestedSize ignored in mGapEnd".
mGapEnd should reflect the total allocated size after the constructor
is executed, i.e. the text buffer is empty. This was not the case.

See thread "Fl_Text_Buffer constructor bug" (2016-12-05) in fltk.general.
The bug was harmless, but the pre-allocation did not work as expected, i.e.
the pre-allocated buffer size was allocated but effectively ignored later.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12134 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-05 17:03:29 +00:00
Manolo Gouy
0701204518 Mention new --enable-print configure option.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12133 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-03 06:59:26 +00:00
Manolo Gouy
c34e8d2725 Undo change at r.12129 that is OK but not really useful.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12132 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-01 22:04:44 +00:00
Manolo Gouy
21781c3fe9 Add --enable-print option to configure to allow building without print support on X11 platforms.
Also, the NO_PRINT_SUPPORT preprocessor variable is renamed FL_NO_PRINT_SUPPORT.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12131 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-01 17:31:29 +00:00
Manolo Gouy
7f3f3f3e08 Rename Fl_Surface_Device::_surface private member variable to surface_ following the CMP.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12130 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-01 06:40:17 +00:00
Manolo Gouy
1458f7e84b CMake building with OPTION_PRINT_SUPPORT off: Fl_Posix_Printer_Driver.cxx should be excluded from compilation.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12129 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-01 06:33:14 +00:00
Manolo Gouy
c794b5ecbd MacOS platform: restore CMake building with OPTION_APPLE_X11 on.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12128 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-01 06:31:25 +00:00
Albrecht Schlosser
d11db7adfa Add missing configure options to configh.in.
Make config.h generated by configure and CMake better comparable.

Note: these options were defined in configh.cmake.in and implemented
only in CMake. Implementation in configure is still missing though.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12127 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-30 14:13:01 +00:00
Manolo Gouy
e5d53b026c Test program "device": add several calls to image destructors to exercise them.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12126 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-30 07:12:29 +00:00
Manolo Gouy
5bb4e853c7 Remove Fl_Image_Surface::end_current() to be called after usage of the drawing surface.
This ensures API compatibility with FLTK 1.3 where Fl_Surface_Device->set_current()
is used to change the current drawing surface.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12125 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-30 07:09:48 +00:00
Manolo Gouy
4755ace9e9 X11 platform: fix STR#3353 and correct drawing of depth-2 RGB images when XRender extension is present.
Fl_RGB_Image's of depth-2, that is, monocolor and transparent, were not drawn using the XRender extension,
when present, as are depth-4 images. With this change they are.
A by-product of this change is that it fixes an erroneous drawing (STR#3353) that occurred when
the image expands outside the window.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12124 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-28 11:32:59 +00:00
Albrecht Schlosser
6fc796738d Fix build with configure --enable-cairo --enable-cairoext.
Add missing #include <config.h>, see this report in fltk.general:

  https://groups.google.com/forum/#!topic/fltkgeneral/x80qQ6wt0s4


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12123 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-25 15:15:09 +00:00
Manolo Gouy
e24409e3ed Remove change at r.12120 because STR#3353 note #6 shows it is not OK.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12122 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-19 08:01:06 +00:00
Albrecht Schlosser
6d4b93e9c7 Finally remove FLTK_ABI_VERSION preprocessor macro from code.
FLTK_ABI_VERSION has been renamed to FL_ABI_VERSION in FLTK 1.4.0.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12121 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-19 01:20:53 +00:00
Manolo Gouy
18d478055e Fix for STR#3353: bad depth-2 image drawing when the window is resized smaller than the image.
The problem is specific to the X11 platform. The cause is that depth-2 images were not considered
in a previous change (r.10628) that introduced transparent image drawing with alpha blending.
Depth-2 images can be processed just as depth-4 images with alpha-blending.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12120 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-18 15:32:33 +00:00
Manolo Gouy
5cf12d94cb X11 platform: Fl_RGB_Image::mask_ is always 0, so remove code to process mask_ in Fl_Xlib_Graphics_Driver.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12119 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-11-18 15:02:34 +00:00