summaryrefslogtreecommitdiff
path: root/test
AgeCommit message (Collapse)Author
2020-11-21Fix Fl_Scrollbar layout in test/valuators demoAlbrecht Schlosser
2020-11-03Add extra argument to Fl_SVG_File_Surface constructor.ManoloFLTK
This makes processing of the underlying FILE object consistant by classes Fl_SVG_File_Surface, Fl_EPS_File_Surface and Fl_PostScript_File_Surface.
2020-10-28Pango ps (#148)ManoloFLTK
Use cairo-PostScript to output PostScript when pango is available. This allows to draw in vectorial form any script. Before, only the Latin script could be drawn to PostScript in vectorial form.
2020-09-07Fix position of the "Return" button.ManoloFLTK
2020-09-01Customize corner radius for rounded box/frame (#130)Albrecht Schlosser
Make maximum box corner radius and shadow width configurable. See Fl::box_border_radius_max() and Fl::box_shadow_width(). Documentation: update image of box types. Fixes #130
2020-08-22Fix .clang-format and some whitespace errorsAlbrecht Schlosser
.clang-format: UseTab: ForIndentation -> Never Update fluid generated files
2020-08-21Fix examples build (configure/make)Albrecht Schlosser
Fix more issues caused by moving fltk-versions from examples to test and adding examples to the CMake build process (gitlab-ci)
2020-08-21CMake: add examples folder to build (optional)Albrecht Schlosser
- replace misnamed option 'OPTION_BUILD_EXAMPLES' with 'FLTK_BUILD_TEST' - add option 'FLTK_BUILD_EXAMPLES' to build apps in examples folder - move examples/fltk-versions.cxx to test/fltk-versions.cxx - [Travis-CI] enable option 'FLTK_BUILD_EXAMPLES' for automatic builds
2020-08-21Remove platform specific code from test appsAlbrecht Schlosser
Test programs that open files don't use platform specific code. They don't open files from macOS bundles. Support files must either be in the current working directory or given on the command line. On macOS this requires a full path when using bundles.
2020-08-21CMake: move test executables to build/bin/testAlbrecht Schlosser
2020-08-08Allow unix style paths for windows native filechooserGreg Ercolano
Allows and preserves unix style paths if user specifies them, otherwise uses Windows style. This allows end users to use either style path and get behavior they expect in cross-platform environments. Addresses problems raised by issue #122
2020-08-03Update dependencies + fluid/generated filesAlbrecht Schlosser
2020-08-01Implement + deploy fl_strdup()Greg Ercolano
2020-07-25Simpler macOS-specific code in main().ManoloFLTK
2020-07-23Git-ignore resize-example* test programsAlbrecht Schlosser
2020-07-23Simpler macOS-specific code.ManoloFLTK
2020-07-23Use local images in test/help_dialog(.html)Albrecht Schlosser
- create subdir test/images - copy images used by test/help_dialog to this subdir - fix image URL's in test/help_dialog.html accordingly CMake: copy the entire test/images folder to the <build>/data folder This enables the demo test/help_dialog.cxx to find its images.
2020-07-22macOS: don't add resource files to demo.appAlbrecht Schlosser
Resources like demo.menu and help_dialog.html are no longer read from the bundle directory on macOS. They are read from the build folder build/data or in case of classic autoconf/make builds from the source directory. We don't need to copy the files into the bundle folder, they are copied to the build/data folder on all platforms anyway.
2020-07-21Fix macOS code + remove obsolete codeAlbrecht Schlosser
Albrecht: - move fl_chdir(data_path) up before fl_getcwd() prints it - add statements to open the argument (i.e. file) with data_path - update comments, remove obsolete code Greg: - on Mac we need absolute path for child filename parameters
2020-07-21Add Fl_Simple_Terminal for cross platform debuggingGreg Ercolano
2020-07-21Consolidate test/demo for all build systemsAlbrecht Schlosser
This is an attempt to unify the code for all build systems (CMake, autotools with make), platforms (operating systems) and toolchains (make + gcc/clang, Visual Studio IDE, Xcode ...) to avoid duplicate code and clarify the differences for future devs and to simplify maintenance. The goal is to minimize the platform specific code. Much of the new code are comments to describe the different situations. The main program does now all the "hard work" to construct the paths necessary to access the other applications and data files. Use macOS specific code to determine the application path (app_path) in main() instead of function dobut(), when test apps are activated. Remove obsolete comments and dead code. Tested on Windows and Linux with both autotools/configure/make and CMake with make (Linux + MinGW), Visual Studio.
2020-07-20add resize examples as per STR3433Duncan Gibson
add example code for creating images for resize.dox based on Article #415: How does resizing work? https://www.fltk.org/articles.php?L415 see also https://www.fltk.org/str.php?L3433
2020-07-20CMake: simplify create_example macroAlbrecht Schlosser
- move target (demo) specific code from macro to CMakeLists.txt - refactor macOS specific code for a cleaner structure - improve documentation Note: CMake ignores platform specific code like creating bundles on other platforms, hence the entire code could be simplified (less conditional code)
2020-07-20Restore tabs in html test fileAlbrecht Schlosser
These tabs were intentional and had been replaced with spaces in the big whitespace fix. This file is an exception!
2020-07-18CMake: simplify copying of test and demo filesAlbrecht Schlosser
2020-07-16Windows: add icon to sudoku.exe (PR #36)Albrecht Schlosser
The changes proposed by Tadej Panjtar (tpanj) were obsolete WRT current Git repo. Thanks to tpanj anyway, I did also apply the simplifications of sudoku.rc.
2020-07-15Restore file icons to 3 macOS test apps who have oneManoloFLTK
2020-07-15CMake: refactor and reformat CMake filesAlbrecht Schlosser
- raise minimum CMake version from 2.6.3 to 3.2.3 (Jun 01, 2015) - indent all CMake files according to the CMP (2 col.) - refactor FLTK version number definitions and usage - unify CMake and autoconf/configure variable names: - FL_VERSION -> FLTK_VERSION - FL_MAJOR_VERSION -> FLTK_VERSION_MAJOR - etc. for _MINOR_ and _PATCH_, respectively - note: this does not affect FL_VERSION etc. in source code - generate "export headers" for all libraries (experimental: OFF) - port some forgotten goodies from branch-1.3 to master - merge and improve macro 'create_example' (WIP) - remove "temporary" options and code for older CMake versions - include and use 'GenerateExportHeader' (experimental, WIP: OFF) - note: created header files are not yet used - build only *one* DLL with Visual Studio (tested, works) - similar to the bundled IDE projects in 1.3.x - add some dynamically linked test/demo programs ('*-shared') if shared libraries are built (WIP) - split 'macros.cmake': use one file per macro
2020-07-14setlocale() added to Fl_File_Chooser demosGreg Ercolano
This change ensures errors in local language. See issue #99 for discussion on why this is needed.
2020-07-11Fix for building without print support (GitHub issue #98).ManoloFLTK
2020-07-06Remove $Id$ tags, update URL's, and moreAlbrecht Schlosser
- remove obsolete svn '$Id$' tags from all source files - update .fl files and generated files accordingly - replace 'http://www.fltk.org' URL's with 'https://...' - replace bug report URL 'str.php' with 'bugs.php' - remove trailing whitespace - fix other whitespace errors flagged by Git - add and/or fix missing or wrong standard headers - convert tabs to spaces in all source files The only relevant code changes are in the fluid/ folder where some .fl files and other source files were used to generate the '$Id' headers and footers.
2020-07-01Fix test/help_dialog for CMake building and macOS platform.ManoloFLTK
2020-06-29Move class Fl_SVG_File_Surface from libfltk to libfltk_images.ManoloFLTK
File examples/SVG_File_Surface.cxx is no longer useful because it was a very partial implementation of what is now class Fl_SVG_File_Surface.
2020-06-27Add classes Fl_SVG_File_Surface and Fl_EPS_File_Surface to draw to SVG and EPS.ManoloFLTK
Test programs device and pixmap_browser use these new classes. Class Fl_SVG_File_Surface can be optionally made non functional using the --disable-svg configure option or turning off OPTION_USE_SVG in CMake. Class Fl_EPS_File_Surface can be optionally made non functional using the --disable-print configure option or turning off OPTION_PRINT_SUPPORT in CMake.
2020-06-21Remove superfluous dependency on forms libraryAlbrecht Schlosser
Some of the test programs were linked with libfltk_forms which was unnecessary. The only one requiring this is the forms demo. [CMake] reordered linked FLTK libs in dependency order.
2020-06-13CMake: Build static and shared libs side-by-sideAlbrecht Schlosser
Clean up library and variable names. Remove '_SHARED' suffix from library (output) filenames. This commit was inspired by David Runge ('dvzrv'), thanks. See PR #21. Fixes #21
2020-06-13Update dependenciesAlbrecht Schlosser
Change sort order using -f (--ignore-case): fold lower case to upper case characters
2020-06-10Support cross-compilation with autotoolsAlbrecht Schlosser
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-01test/clock: close both windows togetherAlbrecht Schlosser
The new window callback demonstrates how to close all (both) windows when the user closes one window.
2020-05-07Extend fl_message_position() with 'center' optionAlbrecht Schlosser
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-04-28Update dependencies and .gitignoreAlbrecht Schlosser
2020-04-22Add optional argument to Fl_Printer::begin_job() to inform caller when an ↵ManoloFLTK
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-20Reorganize .gitignore file(s)Albrecht Schlosser
Move ignored files in /examples/ and /test/ to their own folders, i.e. to examples/.gitignore and test/.gitignore, resp.
2020-04-08Fix copyright headerAlbrecht Schlosser
2020-03-11Remove CodeWarrior "support"Albrecht Schlosser
Metrowerks CodeWarrior was an ancient macOS compiler (discontinued since 2005) that defined the macro __MWERKS__. Code using this macro and several comments have been removed.
2020-02-10Implement fl_putenv() as cross-platform putenv()Albrecht Schlosser
2020-02-09Make test/fullscreen follow what doc of Fl_Window constructor says.ManoloFLTK
That doc says: "Top-level windows initially have visible() set to 0 and parent() set to NULL" and here sw is created as a top-level window, so it must be made visible either by set_visible() or by show().
2020-01-18Add convenience options to glpuzzle demoAlbrecht Schlosser
The demo exhibits a sometimes annoying /feature/ to spin the entire puzzle if a user happens to click and/or drag the mouse somewhere on the puzzle's background rather than on a puzzle piece. A new command line option '-n' disables this feature entirely. The extended menu and keyboard commands learned a new option and keyboard shortcut 'n' => "Normal Position" to stop spinning and to reset the puzzle to its original position. The space key is another (hidden) shortcut for 'n'.
2020-01-18Use cross-platform code to set the window icon.ManoloFLTK
2020-01-16Don't include 'src/flstring.h' in menubar demoAlbrecht Schlosser
src/flstring.h should only be used in library code because it includes <config.h>. Document this fact in src/flstring.h.