Commit Graph

8832 Commits

Author SHA1 Message Date
Albrecht Schlosser
95165884b6 Support cross-compilation with autotools
We use the host system's `fluid` when cross-compiling. This must be
executable as `fluid`, i.e. it must be in the PATH or otherwise
defined, for instance as an alias.
2020-06-10 16:24:39 +02:00
Albrecht Schlosser
3d00b8db4c Improve Fl_SVG_Image docs
- add 'can_expand' optional parameter to scale()
- don't expose name and e-mail of the nanosvg author in docs
- format example code according to the FLTK coding style
- fix (some) trailing spaces

FTR: all examples compile and work well with current FLTK 1.4.
2020-06-07 16:57:40 +02:00
Albrecht Schlosser
1dd4929585 Add two virtual methods to class Fl_Image
(1) The new virtual method Fl_Image::release() which is equivalent to
  'delete this' automatically extends to Fl_Shared_Image::release()
  which makes the latter method virtual.

  This new method in the base class makes Fl_Image::release() callable
  on all objects derived from Fl_Image.

(2) Add virtual method Fl_Shared_Image *Fl_Image::as_shared_image()

  This new method can be used to detect whether an Fl_Image instance
  is an Fl_Shared_Image or not.
2020-06-06 06:27:47 +02:00
ManoloFLTK
6481f95415 Make doc of member function Fl_SVG_Image::resize() more detailed. 2020-06-03 16:03:46 +02:00
ManoloFLTK
f9a63b5ed5 Fix for PR#86: mousewheel simultaneous X and Y scrolling under OS X .
Thanks to the OP for most of the fix.
2020-06-02 19:44:57 +02:00
Albrecht Schlosser
09ee1c0b9c (Git) ignore .vscode folder
The "Visual Studio Code" editor (Open Source by Microsoft) is
becoming more and more popular. It uses a (hidden) folder '.vscode'
in the workspace root directory to store its configurations. We
need to ignore this folder to avoid confusing developers and
checking it in by accident.

See https://github.com/Microsoft/vscode
2020-06-02 14:41:15 +02:00
Albrecht Schlosser
a686e6eafd test/clock: close both windows together
The new window callback demonstrates how to close all (both) windows
when the user closes one window.
2020-06-01 19:06:40 +02:00
Albrecht Schlosser
59a87fe795 Improve Fl_Preferences documentation
This commit fixes typos and reformats some of the documentation.
No code changes.
2020-06-01 18:53:56 +02:00
ManoloFLTK
61d9035e99 Avoid repeated calls to CGBitmapContextGetBytesPerRow(). 2020-06-01 11:04:46 +02:00
ManoloFLTK
897b903f16 Have NSAutoreleasePool released after last use of variable e 2020-05-31 21:19:26 +02:00
ManoloFLTK
9957063398 Protect NSHomeDirectory() call by an NSAutoreleasePool.
That may be necessary if preferences are accessed before fl_open_display() was called.
2020-05-31 11:47:34 +02:00
Albrecht Schlosser
adb2a719d4 Fix fluid undo/redo menu activation and deactivation
(1) fix typo in recent commit
(2) deactivate undo/redo menus on startup and after reset

Fixes issue #84
2020-05-24 22:24:48 +02:00
Greg Ercolano
dcfe826b2f Fix broken undo
Replaced hardwired index#s for undo/redo menu items with dynamic lookup.
2020-05-24 09:02:24 -07:00
Albrecht Schlosser
ec15ac6c89 Fix documentation typos and formatting 2020-05-24 14:18:08 +02:00
Albrecht Schlosser
b1a2c28ad6
Update link in README.md
Sorry for the noise, links with markdown notation don't seem
to work in README.md.
2020-05-24 13:45:58 +02:00
Albrecht Schlosser
e383e73538
Fix filename and remove obsolete info
The file README has been renamed to README.txt some time ago.
2020-05-24 13:43:43 +02:00
ManoloFLTK
026d560fb4 Reorganise code that captures on-screen window content.
Also introduce new rect_to_NSBitmapImageRep: method of class FLWindow
which makes it possible to reimplement it.
2020-05-20 07:51:33 +02:00
Newton
a432db8ca3 Fix "misleading indentation" in Fl_Text_Buffer.cxx
Compiling with clang produced the following warning on this line:

src/Fl_Text_Buffer.cxx:1292:5: warning: misleading indentation; statement is not part of the previous 'if' [-Wmisleading-indentation]
    replace(start, end, text);
    ^
src/Fl_Text_Buffer.cxx:1288:3: note: previous statement is here
  if (!sel->position(&start, &end))
  ^
2020-05-15 23:08:33 +02:00
ManoloFLTK
7f7e0e4ea1 Replace Fl_Window_Driver::is_a_rescale() by Fl_Window::is_a_rescale()
so it can be called by any user code.
2020-05-08 17:08:33 +02:00
Albrecht Schlosser
ccb06e18b7 Fix doxygen docs (wrong argument name) 2020-05-08 12:34:37 +02:00
Albrecht Schlosser
70ce08e0cb Improve fluid documentation
- remove trailing whitespace
- reformat for better readability
- fix typos
2020-05-08 12:31:26 +02:00
Albrecht Schlosser
4ab49d30d3 Merge branch 'pr-30_fl_message_position'
Merge PR #30 with extensions to position the message box centered
over given coordinates or a widget or window.
2020-05-07 17:46:23 +02:00
Albrecht Schlosser
46253603de Extend fl_message_position() with 'center' option
Add argument 'center' to position the message box centered over
  the given x/y coordinates.

Add another method to supply a widget or window to center the
  message box over.

Fix documentation and don't use INT_MIN to avoid having to
  include limits.h in user code.
2020-05-07 17:43:04 +02:00
airbrett
ee7577a897 Add (x,y) positioning mode to common dialogs
Add new function to set (x,y) position.
Reset to previous mode after innards is called by fl_* function.
Use magic number for preferred position state.

Note: several commits squashed and commit messages edited by AlbrechtS.
2020-05-07 14:59:19 +02:00
ManoloFLTK
f386bd2cb7 Support case when window is fullscreen - continued 2020-05-04 11:33:43 +02:00
ManoloFLTK
6d24a355f0 Support case when captured window is fullscreen: no titlebar. 2020-05-04 11:33:43 +02:00
Albrecht Schlosser
70d41b06a9 Reformat src/cmap.cxx and regen src/fl_cmap.h
- remove obsolete code / comments (see Git for history)
- add copyright to generated file src/fl_cmap.h
- generate copyright year in src/fl_cmap.h automatically
- add color indices as comments to color values
- remove $Id header
- replace $Id trailer with a more useful comment
2020-04-29 14:48:00 +02:00
ManoloFLTK
9fe77c6ff5 Minor readability doc change. 2020-04-29 11:24:00 +02:00
Albrecht Schlosser
c1b2e030c5 Update dependencies and .gitignore 2020-04-28 21:20:01 +02:00
ManoloFLTK
4b94485efd Doc: more detail about fl_clip_region() when drawing elsewhere than on the display 2020-04-26 11:31:31 +02:00
ManoloFLTK
dd48bc52dd Misc doc improvements. 2020-04-24 09:30:01 +02:00
ManoloFLTK
255db6c8c4 Doc change with intent to make it clearer. 2020-04-24 08:17:52 +02:00
ManoloFLTK
c4342630f0 Update © year. 2020-04-23 11:30:06 +02:00
ManoloFLTK
f11a80482a Check for success of the FormatMessageW() call. 2020-04-23 11:28:18 +02:00
ManoloFLTK
2ced142adc Match variable type (DWORD) and format specifier 2020-04-22 16:58:48 +02:00
ManoloFLTK
2878fa95ab Add optional argument to Fl_Printer::begin_job() to inform caller when an error occurs.
This solves an issue raised in fltk.general :  Fl_Printer errors - how can I interpret them?
    https://www.fltk.org/newsgroups.php?s38419+gfltk.general+v38427
2020-04-22 16:01:33 +02:00
Albrecht Schlosser
b38317b8a5 Unexpand $Id$ marker in the last remaining file 2020-04-22 15:42:22 +02:00
ManoloFLTK
b3d46711be Slightly improve drawing of window titlebars. 2020-04-21 09:45:43 +02:00
ManoloFLTK
e3ad0ee441 Avoid useless multiplication by 1 operations. 2020-04-21 09:38:39 +02:00
Albrecht Schlosser
811033af19 Reorganize .gitignore file(s)
Move ignored files in /examples/ and /test/ to their own folders,
i.e. to examples/.gitignore and test/.gitignore, resp.
2020-04-20 14:25:08 +02:00
Albrecht Schlosser
dec1938f3c Make draw() protected (Fl_Tree + Fl_Table)
Widget draw() methods must be protected per FLTK convention.
2020-04-20 13:30:48 +02:00
Albrecht Schlosser
40ed1dca41 Fix formatting of Fl_Wizard.H
Fix white space and comments only, no code changes.
2020-04-20 13:28:59 +02:00
Mohammed Alyousef
f203cb8c61 Make draw method protected in Fl_Wizard 2020-04-20 12:52:55 +02:00
ManoloFLTK
75f47a766f Use pkg-config when available to detect pango 2020-04-16 18:04:51 +02:00
ManoloFLTK
bebf554717 Try "pkg-config --cflags pangoxft" to detect presence of pango 2020-04-15 21:30:05 +02:00
ManoloFLTK
6fe226cb80 CMake: use pkg_check_modules to search for pangoxft
Command pkg_check_modules is present in CMake 2.6
2020-04-15 17:07:23 +02:00
Albrecht Schlosser
7ca708a445 Merge PR #71 from Mohammed Alyousef 2020-04-15 00:38:14 +02:00
Mohammed Alyousef
29ec4e0e55 Fix int highlight() comment 2020-04-15 00:35:32 +02:00
ManoloFLTK
b4dd1d36dd Make sure output file name extension is visible. 2020-04-14 21:13:04 +02:00
ManoloFLTK
f3e83d3ce5 MacOS: show print chooser panel as a sheet. 2020-04-12 17:18:44 +02:00