Remove $Id$ tags, update URL's, and more

- 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.
This commit is contained in:
Albrecht Schlosser
2020-07-01 18:03:10 +02:00
parent b0e0c355ed
commit f09e17c3c5
779 changed files with 24817 additions and 28948 deletions

56
.clang-format Executable file → Normal file
View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# clang-format control file for the FLTK project. # clang-format control file for the FLTK project.
# #
# Copyright 2017 by Bill Spitzak and others. # Copyright 2017 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
# #
# Important notes: # Important notes:
@@ -46,11 +44,11 @@
# FLTK settings (currently experimental). # FLTK settings (currently experimental).
BasedOnStyle: LLVM BasedOnStyle: LLVM
# The Language tag marks C++ options # The Language tag marks C++ options
# Language: Cpp # Language: Cpp
# The following options override the LLVM style definitions, if set. # The following options override the LLVM style definitions, if set.
@@ -65,61 +63,61 @@ BasedOnStyle: LLVM
# UseTab can be set to 'Never' (default) or 'ForIndentation' to avoid # UseTab can be set to 'Never' (default) or 'ForIndentation' to avoid
# this annoying bug of clang-format. # this annoying bug of clang-format.
# #
# UseTab: Always # UseTab: Always
UseTab: ForIndentation UseTab: ForIndentation
# Should we extend code lines beyond 80 columns ? # Should we extend code lines beyond 80 columns ?
# Default: 80 # Default: 80
ColumnLimit: 120 ColumnLimit: 120
# The FLTK CMP requires that case labels are indented (LLVM: false) # The FLTK CMP requires that case labels are indented (LLVM: false)
IndentCaseLabels: true IndentCaseLabels: true
# There are sometimes more than 1 empty lines; should we keep 2 or more ? # There are sometimes more than 1 empty lines; should we keep 2 or more ?
# LLVM default is 1. # LLVM default is 1.
MaxEmptyLinesToKeep: 2 MaxEmptyLinesToKeep: 2
# Present FLTK source code contains some short blocks and if statements # Present FLTK source code contains some short blocks and if statements
# in one line, but we should better make it consistent and NOT use the # in one line, but we should better make it consistent and NOT use the
# following "Allow..." statements (leave them commented out): # following "Allow..." statements (leave them commented out):
# #
# LLVM default values: # LLVM default values:
# AllowShortBlocksOnASingleLine: false # AllowShortBlocksOnASingleLine: false
# AllowShortFunctionsOnASingleLine: All # AllowShortFunctionsOnASingleLine: All
# AllowShortIfStatementsOnASingleLine: false # AllowShortIfStatementsOnASingleLine: false
# AllowShortLoopsOnASingleLine: false # AllowShortLoopsOnASingleLine: false
# #
# FLTK values: # FLTK values:
# AllowShortBlocksOnASingleLine: true # AllowShortBlocksOnASingleLine: true
# AllowShortIfStatementsOnASingleLine: true # AllowShortIfStatementsOnASingleLine: true
# Short inline functions in header files are an exception to the above "rule": # Short inline functions in header files are an exception to the above "rule":
AllowShortFunctionsOnASingleLine: Inline AllowShortFunctionsOnASingleLine: Inline
# The following is particularly useful for macros with continuation lines. # The following is particularly useful for macros with continuation lines.
# LLVM default: AlignEscapedNewlinesLeft: false # LLVM default: AlignEscapedNewlinesLeft: false
AlignEscapedNewlinesLeft: true AlignEscapedNewlinesLeft: true
# Include files should be left as-is until we know we can sort them # Include files should be left as-is until we know we can sort them
# without any bad side effects (LLVM: true) # without any bad side effects (LLVM: true)
SortIncludes: false SortIncludes: false
# Multiple constructor initializers must be on consecutive lines: # Multiple constructor initializers must be on consecutive lines:
BreakConstructorInitializersBeforeComma: true BreakConstructorInitializersBeforeComma: true
# Constructor initializers will be indented by 2 spaces (LLVM: 4): # Constructor initializers will be indented by 2 spaces (LLVM: 4):
ConstructorInitializerIndentWidth: 2 ConstructorInitializerIndentWidth: 2
# Continuation lines (if automatically wrapped) may be indented differently. # Continuation lines (if automatically wrapped) may be indented differently.
# This does not apply to function call arguments which are aligned to the # This does not apply to function call arguments which are aligned to the
# opening bracket. LLVM (default): 4 # opening bracket. LLVM (default): 4
# ContinuationIndentWidth: 2 # ContinuationIndentWidth: 2
# Most of FLTK's code uses 'void *p' as opposed to 'void* p'. # Most of FLTK's code uses 'void *p' as opposed to 'void* p'.
# This is particularly useful in combined declarations like: # This is particularly useful in combined declarations like:
@@ -131,9 +129,5 @@ ConstructorInitializerIndentWidth: 2
# Note: this also applies to references like 'int &w, int &h', for instance # Note: this also applies to references like 'int &w, int &h', for instance
# in function parameter lists. # in function parameter lists.
DerivePointerAlignment: false DerivePointerAlignment: false
PointerAlignment: Right PointerAlignment: Right
#
# End of "$Id$".
#

54
.gitattributes vendored
View File

@@ -14,50 +14,50 @@
# files that will not be exported in source tarballs # files that will not be exported in source tarballs
makesrcdist export-ignore eol=lf makesrcdist export-ignore eol=lf
.gitattributes export-ignore .gitattributes export-ignore
.gitignore export-ignore .gitignore export-ignore
.gitlab-ci.yml export-ignore .gitlab-ci.yml export-ignore
.travis.yml export-ignore .travis.yml export-ignore
# fluid files (eol=lf or text?) # fluid files (eol=lf or text?)
*.fl eol=lf *.fl eol=lf
# shell scripts etc. with Unix line endings (lf) # shell scripts etc. with Unix line endings (lf)
*.ac eol=lf *.ac eol=lf
*.in eol=lf *.in eol=lf
*.desktop eol=lf *.desktop eol=lf
*.sh eol=lf *.sh eol=lf
fltk-config.in eol=lf fltk-config.in eol=lf
documentation/make_pdf eol=lf documentation/make_pdf eol=lf
misc/config.guess eol=lf misc/config.guess eol=lf
misc/config.sub eol=lf misc/config.sub eol=lf
misc/update_config_scripts eol=lf misc/update_config_scripts eol=lf
# files with Windows line endings (crlf) # files with Windows line endings (crlf)
*.rc eol=crlf *.rc eol=crlf
*.bat eol=crlf *.bat eol=crlf
# Android Studio special support file (Windows .bat file) # Android Studio special support file (Windows .bat file)
ide/AndroidStudio3/gradlew.rename_to_bat eol=crlf ide/AndroidStudio3/gradlew.rename_to_bat eol=crlf
# binary files # binary files
*.ico binary *.ico binary
*.icns binary *.icns binary
*.jar binary *.jar binary
*.png binary *.png binary
*.jpg binary *.jpg binary
*.ttf binary *.ttf binary
*.xcf binary *.xcf binary
*.xcf_gz binary *.xcf_gz binary
# image files that consist of ASCII text # image files that consist of ASCII text
# *.xbm text # *.xbm text
# *.xpm text # *.xpm text

View File

@@ -1,4 +1,4 @@
Changes in FLTK 1.4.0 Released: ??? ?? 2020 Changes in FLTK 1.4.0 Released: ??? ?? 2020
General Information about this Release General Information about this Release

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,6 +1,4 @@
/* /*
* "$Id$"
*
* Configuration file for the Fast Light Tool Kit (FLTK). * Configuration file for the Fast Light Tool Kit (FLTK).
* *
* Copyright 1998-2020 by Bill Spitzak and others. * Copyright 1998-2020 by Bill Spitzak and others.
@@ -11,9 +9,9 @@
* *
* https://www.fltk.org/COPYING.php * https://www.fltk.org/COPYING.php
* *
* Please report all bugs and problems on the following page: * Please see the following page on how to report bugs and issues:
* *
* https://www.fltk.org/str.php * https://www.fltk.org/bugs.php
*/ */
/* /*
@@ -25,7 +23,3 @@
/* define FL_ABI_VERSION as 10x0y for FLTK ABI version 1.x.y */ /* define FL_ABI_VERSION as 10x0y for FLTK ABI version 1.x.y */
/* #undef FL_ABI_VERSION */ /* #undef FL_ABI_VERSION */
/*
* End of "$Id$".
*/

View File

@@ -36,7 +36,3 @@ if (CMAKE_CROSSCOMPILING)
else () else ()
set (FLTK_FLUID_EXECUTABLE fluid) set (FLTK_FLUID_EXECUTABLE fluid)
endif (CMAKE_CROSSCOMPILING) endif (CMAKE_CROSSCOMPILING)
#
# End of file
#

View File

@@ -68,46 +68,46 @@
message("<FindSDL2.cmake>") message("<FindSDL2.cmake>")
SET(SDL2_SEARCH_PATHS SET(SDL2_SEARCH_PATHS
~/Library/Frameworks ~/Library/Frameworks
/Library/Frameworks /Library/Frameworks
/usr/local /usr/local
/usr /usr
/sw # Fink /sw # Fink
/opt/local # DarwinPorts /opt/local # DarwinPorts
/opt/csw # Blastwave /opt/csw # Blastwave
/opt /opt
${SDL2_PATH} ${SDL2_PATH}
) )
FIND_PATH(SDL2_INCLUDE_DIR SDL.h FIND_PATH(SDL2_INCLUDE_DIR SDL.h
HINTS HINTS
$ENV{SDL2DIR} $ENV{SDL2DIR}
PATH_SUFFIXES include/SDL2 include PATH_SUFFIXES include/SDL2 include
PATHS ${SDL2_SEARCH_PATHS} PATHS ${SDL2_SEARCH_PATHS}
) )
FIND_LIBRARY(SDL2_LIBRARY_TEMP FIND_LIBRARY(SDL2_LIBRARY_TEMP
NAMES SDL2 NAMES SDL2
HINTS HINTS
$ENV{SDL2DIR} $ENV{SDL2DIR}
PATH_SUFFIXES lib64 lib PATH_SUFFIXES lib64 lib
PATHS ${SDL2_SEARCH_PATHS} PATHS ${SDL2_SEARCH_PATHS}
) )
IF(NOT SDL2_BUILDING_LIBRARY) IF(NOT SDL2_BUILDING_LIBRARY)
IF(NOT ${SDL2_INCLUDE_DIR} MATCHES ".framework") IF(NOT ${SDL2_INCLUDE_DIR} MATCHES ".framework")
# Non-OS X framework versions expect you to also dynamically link to # Non-OS X framework versions expect you to also dynamically link to
# SDL2main. This is mainly for Windows and OS X. Other (Unix) platforms # SDL2main. This is mainly for Windows and OS X. Other (Unix) platforms
# seem to provide SDL2main for compatibility even though they don't # seem to provide SDL2main for compatibility even though they don't
# necessarily need it. # necessarily need it.
FIND_LIBRARY(SDL2MAIN_LIBRARY FIND_LIBRARY(SDL2MAIN_LIBRARY
NAMES SDL2main NAMES SDL2main
HINTS HINTS
$ENV{SDL2DIR} $ENV{SDL2DIR}
PATH_SUFFIXES lib64 lib PATH_SUFFIXES lib64 lib
PATHS ${SDL2_SEARCH_PATHS} PATHS ${SDL2_SEARCH_PATHS}
) )
ENDIF(NOT ${SDL2_INCLUDE_DIR} MATCHES ".framework") ENDIF(NOT ${SDL2_INCLUDE_DIR} MATCHES ".framework")
ENDIF(NOT SDL2_BUILDING_LIBRARY) ENDIF(NOT SDL2_BUILDING_LIBRARY)
# SDL2 may require threads on your system. # SDL2 may require threads on your system.
@@ -115,50 +115,50 @@ ENDIF(NOT SDL2_BUILDING_LIBRARY)
# frameworks may already provide it. # frameworks may already provide it.
# But for non-OSX systems, I will use the CMake Threads package. # But for non-OSX systems, I will use the CMake Threads package.
IF(NOT APPLE) IF(NOT APPLE)
FIND_PACKAGE(Threads) FIND_PACKAGE(Threads)
ENDIF(NOT APPLE) ENDIF(NOT APPLE)
# MinGW needs an additional library, mwindows # MinGW needs an additional library, mwindows
# It's total link flags should look like -lmingw32 -lSDL2main -lSDL2 -lmwindows # It's total link flags should look like -lmingw32 -lSDL2main -lSDL2 -lmwindows
# (Actually on second look, I think it only needs one of the m* libraries.) # (Actually on second look, I think it only needs one of the m* libraries.)
IF(MINGW) IF(MINGW)
SET(MINGW32_LIBRARY mingw32 CACHE STRING "mwindows for MinGW") SET(MINGW32_LIBRARY mingw32 CACHE STRING "mwindows for MinGW")
ENDIF(MINGW) ENDIF(MINGW)
IF(SDL2_LIBRARY_TEMP) IF(SDL2_LIBRARY_TEMP)
# For SDL2main # For SDL2main
IF(NOT SDL2_BUILDING_LIBRARY) IF(NOT SDL2_BUILDING_LIBRARY)
IF(SDL2MAIN_LIBRARY) IF(SDL2MAIN_LIBRARY)
SET(SDL2_LIBRARY_TEMP ${SDL2MAIN_LIBRARY} ${SDL2_LIBRARY_TEMP}) SET(SDL2_LIBRARY_TEMP ${SDL2MAIN_LIBRARY} ${SDL2_LIBRARY_TEMP})
ENDIF(SDL2MAIN_LIBRARY) ENDIF(SDL2MAIN_LIBRARY)
ENDIF(NOT SDL2_BUILDING_LIBRARY) ENDIF(NOT SDL2_BUILDING_LIBRARY)
# For OS X, SDL2 uses Cocoa as a backend so it must link to Cocoa. # For OS X, SDL2 uses Cocoa as a backend so it must link to Cocoa.
# CMake doesn't display the -framework Cocoa string in the UI even # CMake doesn't display the -framework Cocoa string in the UI even
# though it actually is there if I modify a pre-used variable. # though it actually is there if I modify a pre-used variable.
# I think it has something to do with the CACHE STRING. # I think it has something to do with the CACHE STRING.
# So I use a temporary variable until the end so I can set the # So I use a temporary variable until the end so I can set the
# "real" variable in one-shot. # "real" variable in one-shot.
IF(APPLE) IF(APPLE)
SET(SDL2_LIBRARY_TEMP ${SDL2_LIBRARY_TEMP} "-framework Cocoa") SET(SDL2_LIBRARY_TEMP ${SDL2_LIBRARY_TEMP} "-framework Cocoa")
ENDIF(APPLE) ENDIF(APPLE)
# For threads, as mentioned Apple doesn't need this. # For threads, as mentioned Apple doesn't need this.
# In fact, there seems to be a problem if I used the Threads package # In fact, there seems to be a problem if I used the Threads package
# and try using this line, so I'm just skipping it entirely for OS X. # and try using this line, so I'm just skipping it entirely for OS X.
IF(NOT APPLE) IF(NOT APPLE)
SET(SDL2_LIBRARY_TEMP ${SDL2_LIBRARY_TEMP} ${CMAKE_THREAD_LIBS_INIT}) SET(SDL2_LIBRARY_TEMP ${SDL2_LIBRARY_TEMP} ${CMAKE_THREAD_LIBS_INIT})
ENDIF(NOT APPLE) ENDIF(NOT APPLE)
# For MinGW library # For MinGW library
IF(MINGW) IF(MINGW)
SET(SDL2_LIBRARY_TEMP ${MINGW32_LIBRARY} ${SDL2_LIBRARY_TEMP}) SET(SDL2_LIBRARY_TEMP ${MINGW32_LIBRARY} ${SDL2_LIBRARY_TEMP})
ENDIF(MINGW) ENDIF(MINGW)
# Set the final string here so the GUI reflects the final state. # Set the final string here so the GUI reflects the final state.
SET(SDL2_LIBRARY ${SDL2_LIBRARY_TEMP} CACHE STRING "Where the SDL2 Library can be found") SET(SDL2_LIBRARY ${SDL2_LIBRARY_TEMP} CACHE STRING "Where the SDL2 Library can be found")
# Set the temp variable to INTERNAL so it is not seen in the CMake GUI # Set the temp variable to INTERNAL so it is not seen in the CMake GUI
SET(SDL2_LIBRARY_TEMP "${SDL2_LIBRARY_TEMP}" CACHE INTERNAL "") SET(SDL2_LIBRARY_TEMP "${SDL2_LIBRARY_TEMP}" CACHE INTERNAL "")
ENDIF(SDL2_LIBRARY_TEMP) ENDIF(SDL2_LIBRARY_TEMP)
message("</FindSDL2.cmake>") message("</FindSDL2.cmake>")

View File

@@ -13,7 +13,3 @@ message(AUTHOR_WARNING
* or later. Please use 'include_directories(\${FLTK_INCLUDE_DIRS})' or * or later. Please use 'include_directories(\${FLTK_INCLUDE_DIRS})' or
* 'target_include_directories(<target> PUBLIC|PRIVATE \${FLTK_INCLUDE_DIRS})' * 'target_include_directories(<target> PUBLIC|PRIVATE \${FLTK_INCLUDE_DIRS})'
* instead of 'include(\${FLTK_USE_FILE})'.") * instead of 'include(\${FLTK_USE_FILE})'.")
#
# End of file
#

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# android.cmake to build the FLTK AndroidStudio project using CMake # android.cmake to build the FLTK AndroidStudio project using CMake
# Written by Matthias Melcher # Written by Matthias Melcher
# #
@@ -10,11 +8,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
# all target modules will be added here later # all target modules will be added here later

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org) # Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org)
# Written by Michael Surette # Written by Michael Surette
# #
@@ -10,11 +8,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
####################################################################### #######################################################################
@@ -79,7 +77,7 @@ configure_file(
if (UNIX) if (UNIX)
execute_process(COMMAND chmod 755 fltk-config execute_process(COMMAND chmod 755 fltk-config
WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
) )
endif (UNIX) endif (UNIX)

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org) # Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org)
# Written by Michael Surette # Written by Michael Surette
# #
@@ -10,11 +8,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
####################################################################### #######################################################################

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# Macros used by the CMake build system for the Fast Light Tool Kit (FLTK). # Macros used by the CMake build system for the Fast Light Tool Kit (FLTK).
# Written by Michael Surette # Written by Michael Surette
# #
@@ -10,11 +8,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
####################################################################### #######################################################################
@@ -59,9 +57,9 @@ macro(FL_ADD_LIBRARY LIBNAME LIBTYPE LIBFILES)
endif (${LIBTYPE} STREQUAL "SHARED") endif (${LIBTYPE} STREQUAL "SHARED")
if (MSVC) if (MSVC)
set (DEBUG_OUTPUT_NAME "${LIBNAME}d") set (DEBUG_OUTPUT_NAME "${LIBNAME}d")
else () else ()
set (DEBUG_OUTPUT_NAME "${LIBNAME}") set (DEBUG_OUTPUT_NAME "${LIBNAME}")
endif (MSVC) endif (MSVC)
add_library(${TARGET_NAME} ${LIBTYPE} ${LIBFILES}) add_library(${TARGET_NAME} ${LIBTYPE} ${LIBFILES})
@@ -72,33 +70,33 @@ macro(FL_ADD_LIBRARY LIBNAME LIBTYPE LIBFILES)
DEBUG_OUTPUT_NAME ${DEBUG_OUTPUT_NAME} DEBUG_OUTPUT_NAME ${DEBUG_OUTPUT_NAME}
CLEAN_DIRECT_OUTPUT TRUE CLEAN_DIRECT_OUTPUT TRUE
COMPILE_DEFINITIONS "FL_LIBRARY" COMPILE_DEFINITIONS "FL_LIBRARY"
) )
if (${LIBTYPE} STREQUAL "SHARED") if (${LIBTYPE} STREQUAL "SHARED")
set_target_properties(${TARGET_NAME} set_target_properties(${TARGET_NAME}
PROPERTIES PROPERTIES
OUTPUT_NAME ${LIBNAME} OUTPUT_NAME ${LIBNAME}
DEBUG_OUTPUT_NAME ${DEBUG_OUTPUT_NAME} DEBUG_OUTPUT_NAME ${DEBUG_OUTPUT_NAME}
VERSION ${FLTK_VERSION_FULL} VERSION ${FLTK_VERSION_FULL}
SOVERSION ${FLTK_VERSION_MAJOR}.${FLTK_VERSION_MINOR} SOVERSION ${FLTK_VERSION_MAJOR}.${FLTK_VERSION_MINOR}
PREFIX "lib" # for MSVC static/shared coexistence PREFIX "lib" # for MSVC static/shared coexistence
) )
endif (${LIBTYPE} STREQUAL "SHARED") endif (${LIBTYPE} STREQUAL "SHARED")
if (MSVC) if (MSVC)
if (OPTION_LARGE_FILE) if (OPTION_LARGE_FILE)
set_target_properties(${TARGET_NAME} set_target_properties(${TARGET_NAME}
PROPERTIES PROPERTIES
LINK_FLAGS /LARGEADDRESSAWARE LINK_FLAGS /LARGEADDRESSAWARE
) )
endif (OPTION_LARGE_FILE) endif (OPTION_LARGE_FILE)
if (${LIBTYPE} STREQUAL "SHARED") if (${LIBTYPE} STREQUAL "SHARED")
set_target_properties(${TARGET_NAME} set_target_properties(${TARGET_NAME}
PROPERTIES PROPERTIES
COMPILE_DEFINITIONS "FL_DLL" COMPILE_DEFINITIONS "FL_DLL"
) )
endif (${LIBTYPE} STREQUAL "SHARED") endif (${LIBTYPE} STREQUAL "SHARED")
endif (MSVC) endif (MSVC)
install(TARGETS ${TARGET_NAME} install(TARGETS ${TARGET_NAME}
@@ -106,7 +104,7 @@ macro(FL_ADD_LIBRARY LIBNAME LIBTYPE LIBFILES)
RUNTIME DESTINATION ${FLTK_BINDIR} RUNTIME DESTINATION ${FLTK_BINDIR}
LIBRARY DESTINATION ${FLTK_LIBDIR} LIBRARY DESTINATION ${FLTK_LIBDIR}
ARCHIVE DESTINATION ${FLTK_LIBDIR} ARCHIVE DESTINATION ${FLTK_LIBDIR}
) )
list(APPEND FLTK_LIBRARIES "${TARGET_NAME}") list(APPEND FLTK_LIBRARIES "${TARGET_NAME}")
set (FLTK_LIBRARIES ${FLTK_LIBRARIES} PARENT_SCOPE) set (FLTK_LIBRARIES ${FLTK_LIBRARIES} PARENT_SCOPE)
@@ -119,14 +117,14 @@ function(FLTK_RUN_FLUID TARGET SOURCES)
set (CXX_FILES) set (CXX_FILES)
foreach(src ${SOURCES}) foreach(src ${SOURCES})
if ("${src}" MATCHES "\\.fl$") if ("${src}" MATCHES "\\.fl$")
string(REGEX REPLACE "(.*).fl" \\1 basename ${src}) string(REGEX REPLACE "(.*).fl" \\1 basename ${src})
add_custom_command( add_custom_command(
OUTPUT "${basename}.cxx" "${basename}.h" OUTPUT "${basename}.cxx" "${basename}.h"
COMMAND fluid -c ${CMAKE_CURRENT_SOURCE_DIR}/${src} COMMAND fluid -c ${CMAKE_CURRENT_SOURCE_DIR}/${src}
DEPENDS ${src} DEPENDS ${src}
MAIN_DEPENDENCY ${src} MAIN_DEPENDENCY ${src}
) )
list(APPEND CXX_FILES "${basename}.cxx") list(APPEND CXX_FILES "${basename}.cxx")
endif ("${src}" MATCHES "\\.fl$") endif ("${src}" MATCHES "\\.fl$")
set (${TARGET} ${CXX_FILES} PARENT_SCOPE) set (${TARGET} ${CXX_FILES} PARENT_SCOPE)
endforeach(src) endforeach(src)
@@ -135,11 +133,11 @@ endfunction(FLTK_RUN_FLUID TARGET SOURCES)
####################################################################### #######################################################################
macro(CREATE_EXAMPLE NAME SOURCES LIBRARIES) macro(CREATE_EXAMPLE NAME SOURCES LIBRARIES)
set (srcs) # source files set (srcs) # source files
set (flsrcs) # fluid source files set (flsrcs) # fluid source files
set (tname ${NAME}) # target name set (tname ${NAME}) # target name
set (oname ${NAME}) # output (executable) name set (oname ${NAME}) # output (executable) name
foreach(src ${SOURCES}) foreach(src ${SOURCES})
if ("${src}" MATCHES "\\.fl$") if ("${src}" MATCHES "\\.fl$")
@@ -151,7 +149,7 @@ macro(CREATE_EXAMPLE NAME SOURCES LIBRARIES)
set (FLUID_SOURCES) set (FLUID_SOURCES)
if (flsrcs) if (flsrcs)
FLTK_RUN_FLUID(FLUID_SOURCES "${flsrcs}") FLTK_RUN_FLUID(FLUID_SOURCES "${flsrcs}")
endif (flsrcs) endif (flsrcs)
if (APPLE AND (NOT OPTION_APPLE_X11) AND (NOT OPTION_APPLE_SDL)) if (APPLE AND (NOT OPTION_APPLE_X11) AND (NOT OPTION_APPLE_SDL))

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org) # Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org)
# Written by Michael Surette # Written by Michael Surette
# #
@@ -12,9 +10,9 @@
# #
# https://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# https://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
set (DEBUG_OPTIONS_CMAKE 0) set (DEBUG_OPTIONS_CMAKE 0)

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org) # Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org)
# Written by Michael Surette # Written by Michael Surette
# #
@@ -10,11 +8,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
####################################################################### #######################################################################
@@ -208,31 +206,31 @@ if(HAVE_DLFCN_H)
endif(HAVE_DLFCN_H) endif(HAVE_DLFCN_H)
set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_DL_LIBS}) set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_DL_LIBS})
CHECK_FUNCTION_EXISTS(dlsym HAVE_DLSYM) CHECK_FUNCTION_EXISTS(dlsym HAVE_DLSYM)
set(CMAKE_REQUIRED_LIBRARIES) set(CMAKE_REQUIRED_LIBRARIES)
CHECK_FUNCTION_EXISTS(localeconv HAVE_LOCALECONV) CHECK_FUNCTION_EXISTS(localeconv HAVE_LOCALECONV)
if(LIB_png) if(LIB_png)
set(CMAKE_REQUIRED_LIBRARIES ${LIB_png}) set(CMAKE_REQUIRED_LIBRARIES ${LIB_png})
CHECK_FUNCTION_EXISTS(png_get_valid HAVE_PNG_GET_VALID) CHECK_FUNCTION_EXISTS(png_get_valid HAVE_PNG_GET_VALID)
CHECK_FUNCTION_EXISTS(png_set_tRNS_to_alpha HAVE_PNG_SET_TRNS_TO_ALPHA) CHECK_FUNCTION_EXISTS(png_set_tRNS_to_alpha HAVE_PNG_SET_TRNS_TO_ALPHA)
set(CMAKE_REQUIRED_LIBRARIES) set(CMAKE_REQUIRED_LIBRARIES)
endif(LIB_png) endif(LIB_png)
CHECK_FUNCTION_EXISTS(scandir HAVE_SCANDIR) CHECK_FUNCTION_EXISTS(scandir HAVE_SCANDIR)
CHECK_FUNCTION_EXISTS(snprintf HAVE_SNPRINTF) CHECK_FUNCTION_EXISTS(snprintf HAVE_SNPRINTF)
# not really true but we convert strcasecmp calls to _stricmp calls in flstring.h # not really true but we convert strcasecmp calls to _stricmp calls in flstring.h
if(MSVC) if(MSVC)
set(HAVE_STRCASECMP 1) set(HAVE_STRCASECMP 1)
endif(MSVC) endif(MSVC)
CHECK_FUNCTION_EXISTS(strcasecmp HAVE_STRCASECMP) CHECK_FUNCTION_EXISTS(strcasecmp HAVE_STRCASECMP)
CHECK_FUNCTION_EXISTS(strlcat HAVE_STRLCAT) CHECK_FUNCTION_EXISTS(strlcat HAVE_STRLCAT)
CHECK_FUNCTION_EXISTS(strlcpy HAVE_STRLCPY) CHECK_FUNCTION_EXISTS(strlcpy HAVE_STRLCPY)
CHECK_FUNCTION_EXISTS(vsnprintf HAVE_VSNPRINTF) CHECK_FUNCTION_EXISTS(vsnprintf HAVE_VSNPRINTF)
if(HAVE_SCANDIR AND NOT HAVE_SCANDIR_POSIX) if(HAVE_SCANDIR AND NOT HAVE_SCANDIR_POSIX)
set(MSG "POSIX compatible scandir") set(MSG "POSIX compatible scandir")
@@ -285,7 +283,3 @@ endif (DOXYGEN_FOUND)
# Cleanup: unset local variables # Cleanup: unset local variables
unset (CMAKE_REQUIRED_QUIET) unset (CMAKE_REQUIRED_QUIET)
#
# End of "$Id$".
#

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# CMakeLists.txt to build the FLTK project using CMake (www.cmake.org) # CMakeLists.txt to build the FLTK project using CMake (www.cmake.org)
# Written by Michael Surette # Written by Michael Surette
# #
@@ -10,11 +8,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
####################################################################### #######################################################################

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# This file sets variables for common use in export.cmake and install.cmake # This file sets variables for common use in export.cmake and install.cmake
# Written by Michael Surette # Written by Michael Surette
# #
@@ -10,11 +8,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
####################################################################### #######################################################################

View File

@@ -1,6 +1,4 @@
# #
# "$Id$"
#
# Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org) # Main CMakeLists.txt to build the FLTK project using CMake (www.cmake.org)
# Written by Michael Surette # Written by Michael Surette
# #
@@ -10,11 +8,11 @@
# the file "COPYING" which should have been included with this file. If this # the file "COPYING" which should have been included with this file. If this
# file is missing or damaged, see the license at: # file is missing or damaged, see the license at:
# #
# http://www.fltk.org/COPYING.php # https://www.fltk.org/COPYING.php
# #
# Please report all bugs and problems on the following page: # Please see the following page on how to report bugs and issues:
# #
# http://www.fltk.org/str.php # https://www.fltk.org/bugs.php
# #
# Prevent annoying warning under Cygwin; this must be before project(). # Prevent annoying warning under Cygwin; this must be before project().

View File

@@ -14,7 +14,7 @@ exceptions:
contributed to the FLTK project - send all contributions contributed to the FLTK project - send all contributions
through the "Software Trouble Report" on the following page: through the "Software Trouble Report" on the following page:
http://www.fltk.org/str.php https://www.fltk.org/bugs.php
2. Widgets that are subclassed from FLTK widgets do not 2. Widgets that are subclassed from FLTK widgets do not
constitute a derivative work. constitute a derivative work.
@@ -42,7 +42,7 @@ exceptions:
documentation to satisfy this requirement: documentation to satisfy this requirement:
[program/widget] is based in part on the work of [program/widget] is based in part on the work of
the FLTK project (http://www.fltk.org). the FLTK project (https://www.fltk.org).
----------------------------------------------------------------------- -----------------------------------------------------------------------

View File

@@ -1,71 +1,71 @@
CREDITS.txt - Fast Light Tool Kit (FLTK) Version 1.4.0 CREDITS.txt - Fast Light Tool Kit (FLTK) Version 1.4.0
------------------------------------------------------ ------------------------------------------------------
This file lists the people responsible for the toolkit you are This file lists the people responsible for the toolkit you are
now using. If you've been looking for your name in lights now using. If you've been looking for your name in lights
but we've forgotten you here, please use the report on the but we've forgotten you here, please use the report on the
following page, and we'll update this file accordingly: following page, and we'll update this file accordingly:
https://www.fltk.org/str.php https://www.fltk.org/bugs.php
CORE DEVELOPERS CORE DEVELOPERS
The following people do the day-to-day development of FLTK: The following people do the day-to-day development of FLTK:
Greg Ercolano Greg Ercolano
Manolo Gouy Manolo Gouy
Lauri Kasanen Lauri Kasanen
Ian MacArthur Ian MacArthur
Pierre Ossman Pierre Ossman
Albrecht Schlosser Albrecht Schlosser
These people have previously been active developers of FLTK: These people have previously been active developers of FLTK:
Fabien Costantini (fabien67@users.sf.net) Fabien Costantini (fabien67@users.sf.net)
Craig P. Earls Craig P. Earls
Curtis Edwards (trilec@users.sourceforge.net) Curtis Edwards (trilec@users.sourceforge.net)
Gustavo Hime (hime@users.sourceforge.net) Gustavo Hime (hime@users.sourceforge.net)
Talbot Hughes Talbot Hughes
Robert Kesterson (robertk@users.sourceforge.net) Robert Kesterson (robertk@users.sourceforge.net)
Matthias Melcher (mm@robowerk.com) Matthias Melcher (mm@robowerk.com)
James Dean Palmer (jamespalmer@users.sourceforge.net) James Dean Palmer (jamespalmer@users.sourceforge.net)
Vincent Penne (vincentp@users.sourceforge.net) Vincent Penne (vincentp@users.sourceforge.net)
Bill Spitzak (spitzak@users.sourceforge.net) Bill Spitzak (spitzak@users.sourceforge.net)
Michael Sweet (easysw@users.sourceforge.net) Michael Sweet (easysw@users.sourceforge.net)
Carl Thompson (clip@users.sourceforge.net) Carl Thompson (clip@users.sourceforge.net)
Nafees Bin Zafar (nafees@users.sourceforge.net) Nafees Bin Zafar (nafees@users.sourceforge.net)
OTHER CONTRIBUTORS OTHER CONTRIBUTORS
The following people have contributed fixes or enhancements The following people have contributed fixes or enhancements
for FLTK: for FLTK:
Laszlo Z. Antal (LZA) Laszlo Z. Antal (LZA)
Teun Burgers Teun Burgers
Paul Chambers Paul Chambers
Stephen Davies Stephen Davies
Yuri D'Elia Yuri D'Elia
Domingo Alvarez Duarte Domingo Alvarez Duarte
Yuri Fedorchenko Yuri Fedorchenko
George Garvey George Garvey
Duncan Gibson Duncan Gibson
Mikael Hultgren Mikael Hultgren
Stuart Levy Stuart Levy
Jean-Marc Lienher (OksiD) Jean-Marc Lienher (OksiD)
Howard Lightstone Howard Lightstone
Mike Lindner Mike Lindner
Alexander Mai Alexander Mai
Alexander Rabi Alexander Rabi
James Roth James Roth
Ivan Nieto (Mr.Satan) Ivan Nieto (Mr.Satan)
Jamie Snape Jamie Snape
Andrea Suatoni Andrea Suatoni
Michael Surette Michael Surette
Paul Sydney Paul Sydney
Aaron Ucko Aaron Ucko
Emanuele Vicentini Emanuele Vicentini
Josef Vitu Josef Vitu
Jim Wilson Jim Wilson
Ken Yarnall Ken Yarnall

View File

@@ -9,7 +9,7 @@ SET (DROP_LOCATION "/cgi-bin/HTTPUploadDartFile.cgi")
SET (TRIGGER_SITE "http://${DROP_SITE}/cgi-bin/Submit-Fltk-TestingResults.pl") SET (TRIGGER_SITE "http://${DROP_SITE}/cgi-bin/Submit-Fltk-TestingResults.pl")
# Project Home Page # Project Home Page
SET (PROJECT_URL "http://www.fltk.org") SET (PROJECT_URL "https://www.fltk.org")
# Dart server configuration # Dart server configuration
SET (ROLLUP_URL "http://${DROP_SITE}/cgi-bin/fltk-rollup-dashboard.sh") SET (ROLLUP_URL "http://${DROP_SITE}/cgi-bin/fltk-rollup-dashboard.sh")
@@ -17,7 +17,7 @@ SET (CVS_WEB_URL "http://cvs.sourceforge.net/viewcvs.py/fltk/fltk/")
SET (CVS_WEB_CVSROOT "fltk") SET (CVS_WEB_CVSROOT "fltk")
SET (USE_GNATS "On") SET (USE_GNATS "On")
SET (GNATS_WEB_URL "http://www.fltk.org/str.php") SET (GNATS_WEB_URL "https://www.fltk.org/bugs.php")
# Continuous email delivery variables # Continuous email delivery variables
SET (CONTINUOUS_FROM "fltk-dashboard@public.kitware.com") SET (CONTINUOUS_FROM "fltk-dashboard@public.kitware.com")

File diff suppressed because it is too large Load Diff

118
FL/Fl.H
View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Main header file for the Fast Light Tool Kit (FLTK). // Main header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2020 by Bill Spitzak and others. // Copyright 1998-2020 by Bill Spitzak and others.
@@ -11,9 +9,9 @@
// //
// https://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// https://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/** \file /** \file
@@ -33,7 +31,7 @@
# include "fl_utf8.h" # include "fl_utf8.h"
# include "Enumerations.H" # include "Enumerations.H"
# ifndef Fl_Object # ifndef Fl_Object
# define Fl_Object Fl_Widget /**< for back compatibility - use Fl_Widget! */ # define Fl_Object Fl_Widget /**< for back compatibility - use Fl_Widget! */
# endif # endif
# ifdef check # ifdef check
@@ -72,7 +70,7 @@ extern FL_EXPORT const char* fl_local_shift; ///< string pointer used in shortcu
callback function to handle such events in the user's code. callback function to handle such events in the user's code.
\see Fl::add_handler(), Fl::add_timeout(), Fl::repeat_timeout(), \see Fl::add_handler(), Fl::add_timeout(), Fl::repeat_timeout(),
Fl::remove_timeout() and others Fl::remove_timeout() and others
@{ */ @{ */
/** Signature of some label drawing functions passed as parameters */ /** Signature of some label drawing functions passed as parameters */
@@ -302,7 +300,7 @@ public:
static int e_original_keysym; // late addition static int e_original_keysym; // late addition
static int scrollbar_size_; static int scrollbar_size_;
static int menu_linespacing_; // STR #2927 static int menu_linespacing_; // STR #2927
#endif #endif
@@ -622,8 +620,8 @@ int main() {
/** @} */ /** @} */
/** \defgroup fl_events Events handling functions /** \defgroup fl_events Events handling functions
Fl class events handling API declared in <FL/Fl.H> Fl class events handling API declared in <FL/Fl.H>
@{ @{
*/ */
// event information: // event information:
/** /**
@@ -631,41 +629,41 @@ int main() {
to determine if a callback is being done in response to a to determine if a callback is being done in response to a
keypress, mouse click, etc. keypress, mouse click, etc.
*/ */
static int event() {return e_number;} static int event() {return e_number;}
/** /**
Returns the mouse position of the event relative to the Fl_Window Returns the mouse position of the event relative to the Fl_Window
it was passed to. it was passed to.
*/ */
static int event_x() {return e_x;} static int event_x() {return e_x;}
/** /**
Returns the mouse position of the event relative to the Fl_Window Returns the mouse position of the event relative to the Fl_Window
it was passed to. it was passed to.
*/ */
static int event_y() {return e_y;} static int event_y() {return e_y;}
/** /**
Returns the mouse position on the screen of the event. To find the Returns the mouse position on the screen of the event. To find the
absolute position of an Fl_Window on the screen, use the absolute position of an Fl_Window on the screen, use the
difference between event_x_root(),event_y_root() and difference between event_x_root(),event_y_root() and
event_x(),event_y(). event_x(),event_y().
*/ */
static int event_x_root() {return e_x_root;} static int event_x_root() {return e_x_root;}
/** /**
Returns the mouse position on the screen of the event. To find the Returns the mouse position on the screen of the event. To find the
absolute position of an Fl_Window on the screen, use the absolute position of an Fl_Window on the screen, use the
difference between event_x_root(),event_y_root() and difference between event_x_root(),event_y_root() and
event_x(),event_y(). event_x(),event_y().
*/ */
static int event_y_root() {return e_y_root;} static int event_y_root() {return e_y_root;}
/** /**
Returns the current horizontal mouse scrolling associated with the Returns the current horizontal mouse scrolling associated with the
FL_MOUSEWHEEL event. Right is positive. FL_MOUSEWHEEL event. Right is positive.
*/ */
static int event_dx() {return e_dx;} static int event_dx() {return e_dx;}
/** /**
Returns the current vertical mouse scrolling associated with the Returns the current vertical mouse scrolling associated with the
FL_MOUSEWHEEL event. Down is positive. FL_MOUSEWHEEL event. Down is positive.
*/ */
static int event_dy() {return e_dy;} static int event_dy() {return e_dy;}
/** /**
Return where the mouse is on the screen by doing a round-trip query to Return where the mouse is on the screen by doing a round-trip query to
the server. You should use Fl::event_x_root() and the server. You should use Fl::event_x_root() and
@@ -683,7 +681,7 @@ int main() {
again while event_is_click() is true. again while event_is_click() is true.
*/ */
static int event_clicks() {return e_clicks;} static int event_clicks() {return e_clicks;}
/** /**
Manually sets the number returned by Fl::event_clicks(). Manually sets the number returned by Fl::event_clicks().
This can be used to set it to zero so that This can be used to set it to zero so that
@@ -699,7 +697,7 @@ int main() {
"click". You can test this on FL_DRAG, FL_RELEASE, "click". You can test this on FL_DRAG, FL_RELEASE,
and FL_MOVE events. and FL_MOVE events.
*/ */
static int event_is_click() {return e_is_click;} static int event_is_click() {return e_is_click;}
/** /**
Clears the value returned by Fl::event_is_click(). Clears the value returned by Fl::event_is_click().
Useful to prevent the <I>next</I> Useful to prevent the <I>next</I>
@@ -716,7 +714,7 @@ int main() {
\retval FL_RIGHT_MOUSE. \retval FL_RIGHT_MOUSE.
\see Fl::event_buttons() \see Fl::event_buttons()
*/ */
static int event_button() {return e_keysym-FL_Button;} static int event_button() {return e_keysym-FL_Button;}
/** /**
Returns the keyboard and mouse button states of the last event. Returns the keyboard and mouse button states of the last event.
@@ -742,7 +740,7 @@ int main() {
so that the shift state is not correctly reported until the first event so that the shift state is not correctly reported until the first event
<I>after</I> the shift key is pressed or released. <I>after</I> the shift key is pressed or released.
*/ */
static int event_state() {return e_state;} static int event_state() {return e_state;}
/** Returns non-zero if any of the passed event state bits are turned on. /** Returns non-zero if any of the passed event state bits are turned on.
@@ -761,7 +759,7 @@ int main() {
\returns an integer 'key code', or 0 if the last event was not a key press or release. \returns an integer 'key code', or 0 if the last event was not a key press or release.
\see int event_key(int), event_text(), compose(int&). \see int event_key(int), event_text(), compose(int&).
*/ */
static int event_key() {return e_keysym;} static int event_key() {return e_keysym;}
/** /**
Returns the keycode of the last key event, regardless of the NumLock state. Returns the keycode of the last key event, regardless of the NumLock state.
@@ -785,25 +783,25 @@ int main() {
on the keyboard: on the keyboard:
\li All keys on the main keyboard producing a printable ASCII \li All keys on the main keyboard producing a printable ASCII
character use the value of that ASCII character (as though shift, character use the value of that ASCII character (as though shift,
ctrl, and caps lock were not on). The space bar is 32. ctrl, and caps lock were not on). The space bar is 32.
\li All keys on the numeric keypad producing a printable ASCII \li All keys on the numeric keypad producing a printable ASCII
character use the value of that ASCII character plus FL_KP. character use the value of that ASCII character plus FL_KP.
The highest possible value is FL_KP_Last so you can The highest possible value is FL_KP_Last so you can
range-check to see if something is on the keypad. range-check to see if something is on the keypad.
\li All numbered function keys use the number on the function key plus \li All numbered function keys use the number on the function key plus
FL_F. The highest possible number is FL_F_Last, so you FL_F. The highest possible number is FL_F_Last, so you
can range-check a value. can range-check a value.
\li Buttons on the mouse are considered keys, and use the button \li Buttons on the mouse are considered keys, and use the button
number (where the left button is 1) plus FL_Button. number (where the left button is 1) plus FL_Button.
\li All other keys on the keypad have a symbol: FL_Escape, \li All other keys on the keypad have a symbol: FL_Escape,
FL_BackSpace, FL_Tab, FL_Enter, FL_Print, FL_Scroll_Lock, FL_Pause, FL_BackSpace, FL_Tab, FL_Enter, FL_Print, FL_Scroll_Lock, FL_Pause,
FL_Insert, FL_Home, FL_Page_Up, FL_Delete, FL_End, FL_Page_Down, FL_Insert, FL_Home, FL_Page_Up, FL_Delete, FL_End, FL_Page_Down,
FL_Left, FL_Up, FL_Right, FL_Down, FL_Iso_Key, FL_Shift_L, FL_Shift_R, FL_Left, FL_Up, FL_Right, FL_Down, FL_Iso_Key, FL_Shift_L, FL_Shift_R,
FL_Control_L, FL_Control_R, FL_Caps_Lock, FL_Alt_L, FL_Alt_R, FL_Control_L, FL_Control_R, FL_Caps_Lock, FL_Alt_L, FL_Alt_R,
FL_Meta_L, FL_Meta_R, FL_Menu, FL_Num_Lock, FL_KP_Enter. Be FL_Meta_L, FL_Meta_R, FL_Menu, FL_Num_Lock, FL_KP_Enter. Be
careful not to confuse these with the very similar, but all-caps, careful not to confuse these with the very similar, but all-caps,
symbols used by Fl::event_state(). symbols used by Fl::event_state().
On X Fl::get_key(FL_Button+n) does not work. On X Fl::get_key(FL_Button+n) does not work.
@@ -867,10 +865,10 @@ int main() {
static void belowmouse(Fl_Widget*); static void belowmouse(Fl_Widget*);
/** Gets the widget that is being pushed. /** Gets the widget that is being pushed.
\see void pushed(Fl_Widget*) */ \see void pushed(Fl_Widget*) */
static Fl_Widget* pushed() {return pushed_;} static Fl_Widget* pushed() {return pushed_;}
static void pushed(Fl_Widget*); static void pushed(Fl_Widget*);
/** Gets the current Fl::focus() widget. \sa Fl::focus(Fl_Widget*) */ /** Gets the current Fl::focus() widget. \sa Fl::focus(Fl_Widget*) */
static Fl_Widget* focus() {return focus_;} static Fl_Widget* focus() {return focus_;}
static void focus(Fl_Widget*); static void focus(Fl_Widget*);
static void add_handler(Fl_Event_Handler h); static void add_handler(Fl_Event_Handler h);
static void remove_handler(Fl_Event_Handler h); static void remove_handler(Fl_Event_Handler h);
@@ -881,7 +879,7 @@ int main() {
/** @} */ /** @} */
/** \defgroup fl_clipboard Selection & Clipboard functions /** \defgroup fl_clipboard Selection & Clipboard functions
FLTK global copy/cut/paste functions declared in <FL/Fl.H> FLTK global copy/cut/paste functions declared in <FL/Fl.H>
@{ */ @{ */
// cut/paste: // cut/paste:
/** /**
@@ -954,13 +952,13 @@ int main() {
\code \code
void clip_callback(int source, void *data) { void clip_callback(int source, void *data) {
if ( source == 0 ) printf("CLIP CALLBACK: selection buffer changed\n"); if ( source == 0 ) printf("CLIP CALLBACK: selection buffer changed\n");
if ( source == 1 ) printf("CLIP CALLBACK: clipboard changed\n"); if ( source == 1 ) printf("CLIP CALLBACK: clipboard changed\n");
} }
[..] [..]
int main() { int main() {
[..] [..]
Fl::add_clipboard_notify(clip_callback); Fl::add_clipboard_notify(clip_callback);
[..] [..]
} }
\endcode \endcode
\note Some systems require polling to monitor the clipboard and may \note Some systems require polling to monitor the clipboard and may
@@ -1046,25 +1044,25 @@ int main() {
/** \defgroup fl_attributes Color & Font functions /** \defgroup fl_attributes Color & Font functions
fl global color, font functions. fl global color, font functions.
These functions are declared in <FL/Fl.H> or <FL/fl_draw.H>. These functions are declared in <FL/Fl.H> or <FL/fl_draw.H>.
@{ */ @{ */
// color map: // color map:
static void set_color(Fl_Color, uchar, uchar, uchar); static void set_color(Fl_Color, uchar, uchar, uchar);
/** /**
Sets an entry in the fl_color index table. You can set it to any Sets an entry in the fl_color index table. You can set it to any
8-bit RGB color. The color is not allocated until fl_color(i) is used. 8-bit RGB color. The color is not allocated until fl_color(i) is used.
*/ */
static void set_color(Fl_Color i, unsigned c); // platform dependent static void set_color(Fl_Color i, unsigned c); // platform dependent
static unsigned get_color(Fl_Color i); static unsigned get_color(Fl_Color i);
static void get_color(Fl_Color i, uchar &red, uchar &green, uchar &blue); static void get_color(Fl_Color i, uchar &red, uchar &green, uchar &blue);
/** /**
Frees the specified color from the colormap, if applicable. Frees the specified color from the colormap, if applicable.
If overlay is non-zero then the color is freed from the If overlay is non-zero then the color is freed from the
overlay colormap. overlay colormap.
*/ */
static void free_color(Fl_Color i, int overlay = 0); // platform dependent static void free_color(Fl_Color i, int overlay = 0); // platform dependent
// fonts: // fonts:
static const char* get_font(Fl_Font); static const char* get_font(Fl_Font);
@@ -1234,7 +1232,7 @@ int main() {
*/ */
static int dnd_text_ops() { return option(OPTION_DND_TEXT); } static int dnd_text_ops() { return option(OPTION_DND_TEXT); }
/** \defgroup fl_multithread Multithreading support functions /** \defgroup fl_multithread Multithreading support functions
fl multithreading support functions declared in <FL/Fl.H> fl multithreading support functions declared in <FL/Fl.H>
@{ */ @{ */
// Multithreading support: // Multithreading support:
@@ -1268,17 +1266,17 @@ int main() {
There are three groups of related methods: There are three groups of related methods:
-# scheduled widget deletion -# scheduled widget deletion
- Fl::delete_widget() schedules widgets for deletion - Fl::delete_widget() schedules widgets for deletion
- Fl::do_widget_deletion() deletes all scheduled widgets - Fl::do_widget_deletion() deletes all scheduled widgets
-# widget watch list ("smart pointers") -# widget watch list ("smart pointers")
- Fl::watch_widget_pointer() adds a widget pointer to the watch list - Fl::watch_widget_pointer() adds a widget pointer to the watch list
- Fl::release_widget_pointer() removes a widget pointer from the watch list - Fl::release_widget_pointer() removes a widget pointer from the watch list
- Fl::clear_widget_pointer() clears a widget pointer \e in the watch list - Fl::clear_widget_pointer() clears a widget pointer \e in the watch list
-# the class Fl_Widget_Tracker: -# the class Fl_Widget_Tracker:
- the constructor calls Fl::watch_widget_pointer() - the constructor calls Fl::watch_widget_pointer()
- the destructor calls Fl::release_widget_pointer() - the destructor calls Fl::release_widget_pointer()
- the access methods can be used to test, if a widget has been deleted - the access methods can be used to test, if a widget has been deleted
\see Fl_Widget_Tracker. \see Fl_Widget_Tracker.
@{ */ @{ */
// Widget deletion: // Widget deletion:
@@ -1454,12 +1452,8 @@ public:
}; };
/** \defgroup fl_unicode Unicode and UTF-8 functions /** \defgroup fl_unicode Unicode and UTF-8 functions
fl global Unicode and UTF-8 handling functions declared in <FL/fl_utf8.h> fl global Unicode and UTF-8 handling functions declared in <FL/fl_utf8.h>
@{ */ @{ */
/** @} */ /** @} */
#endif // !Fl_H #endif // !Fl_H
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Adjuster widget header file for the Fast Light Tool Kit (FLTK). // Adjuster widget header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -67,7 +65,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// BMP image header file for the Fast Light Tool Kit (FLTK). // BMP image header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2020 by Bill Spitzak and others. // Copyright 1998-2020 by Bill Spitzak and others.
@@ -11,9 +9,9 @@
// //
// https://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// https://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -41,7 +39,3 @@ class FL_EXPORT Fl_BMP_Image : public Fl_RGB_Image {
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Bitmap header file for the Fast Light Tool Kit (FLTK). // Bitmap header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2017 by Bill Spitzak and others. // Copyright 1998-2017 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -62,7 +60,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Box header file for the Fast Light Tool Kit (FLTK). // Box header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -53,7 +51,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Browser header file for the Fast Light Tool Kit (FLTK). // Browser header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2016 by Bill Spitzak and others. // Copyright 1998-2016 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -76,7 +74,7 @@ struct FL_BLINE;
\code \code
// How to loop through all the items in the browser // How to loop through all the items in the browser
for ( int t=1; t<=browser->size(); t++ ) { // index 1 based..! for ( int t=1; t<=browser->size(); t++ ) { // index 1 based..!
printf("item #%d, label='%s'\n", t, browser->text(t)); printf("item #%d, label='%s'\n", t, browser->text(t));
} }
\endcode \endcode
@@ -87,15 +85,15 @@ struct FL_BLINE;
*/ */
class FL_EXPORT Fl_Browser : public Fl_Browser_ { class FL_EXPORT Fl_Browser : public Fl_Browser_ {
FL_BLINE *first; // the array of lines FL_BLINE *first; // the array of lines
FL_BLINE *last; FL_BLINE *last;
FL_BLINE *cache; FL_BLINE *cache;
int cacheline; // line number of cache int cacheline; // line number of cache
int lines; // Number of lines int lines; // Number of lines
int full_height_; int full_height_;
const int* column_widths_; const int* column_widths_;
char format_char_; // alternative to @-sign char format_char_; // alternative to @-sign
char column_char_; // alternative to tab char column_char_; // alternative to tab
protected: protected:
@@ -330,7 +328,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Common browser header file for the Fast Light Tool Kit (FLTK). // Common browser header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2016 by Bill Spitzak and others. // Copyright 1998-2016 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -28,15 +26,15 @@
#include "Fl_Group.H" #include "Fl_Group.H"
#endif #endif
#include "Fl_Scrollbar.H" #include "Fl_Scrollbar.H"
#include <FL/Fl.H> // Fl::scrollbar_size() #include <FL/Fl.H> // Fl::scrollbar_size()
#define FL_NORMAL_BROWSER 0 /**< type() of Fl_Browser */ #define FL_NORMAL_BROWSER 0 /**< type() of Fl_Browser */
#define FL_SELECT_BROWSER 1 /**< type() of FL_Select_Browser */ #define FL_SELECT_BROWSER 1 /**< type() of FL_Select_Browser */
#define FL_HOLD_BROWSER 2 /**< type() of Fl_Hold_Browser */ #define FL_HOLD_BROWSER 2 /**< type() of Fl_Hold_Browser */
#define FL_MULTI_BROWSER 3 /**< type() of Fl_Multi_Browser */ #define FL_MULTI_BROWSER 3 /**< type() of Fl_Multi_Browser */
#define FL_SORT_ASCENDING 0 /**< sort browser items in ascending alphabetic order. */ #define FL_SORT_ASCENDING 0 /**< sort browser items in ascending alphabetic order. */
#define FL_SORT_DESCENDING 1 /**< sort in descending order */ #define FL_SORT_DESCENDING 1 /**< sort in descending order */
/** /**
This is the base class for browsers. To be useful it must be This is the base class for browsers. To be useful it must be
@@ -76,21 +74,21 @@ Keyboard navigation of browser items
extend a selection or de-selection. extend a selection or de-selection.
*/ */
class FL_EXPORT Fl_Browser_ : public Fl_Group { class FL_EXPORT Fl_Browser_ : public Fl_Group {
int position_; // where user wants it scrolled to int position_; // where user wants it scrolled to
int real_position_; // the current vertical scrolling position int real_position_; // the current vertical scrolling position
int hposition_; // where user wants it panned to int hposition_; // where user wants it panned to
int real_hposition_; // the current horizontal scrolling position int real_hposition_; // the current horizontal scrolling position
int offset_; // how far down top_ item the real_position is int offset_; // how far down top_ item the real_position is
int max_width; // widest object seen so far int max_width; // widest object seen so far
uchar has_scrollbar_; // which scrollbars are enabled uchar has_scrollbar_; // which scrollbars are enabled
Fl_Font textfont_; Fl_Font textfont_;
Fl_Fontsize textsize_; Fl_Fontsize textsize_;
Fl_Color textcolor_; Fl_Color textcolor_;
void* top_; // which item scrolling position is in void* top_; // which item scrolling position is in
void* selection_; // which is selected (except for FL_MULTI_BROWSER) void* selection_; // which is selected (except for FL_MULTI_BROWSER)
void *redraw1,*redraw2; // minimal update pointers void *redraw1,*redraw2; // minimal update pointers
void* max_width_item; // which item has max_width_ void* max_width_item; // which item has max_width_
int scrollbar_size_; // size of scrollbar trough int scrollbar_size_; // size of scrollbar trough
void update_top(); void update_top();
@@ -164,9 +162,9 @@ protected:
*/ */
virtual void *item_at(int index) const { (void)index; return 0L; } virtual void *item_at(int index) const { (void)index; return 0L; }
// you don't have to provide these but it may help speed it up: // you don't have to provide these but it may help speed it up:
virtual int full_width() const ; // current width of all items virtual int full_width() const ; // current width of all items
virtual int full_height() const ; // current height of all items virtual int full_height() const ; // current height of all items
virtual int incr_height() const ; // average height of an item virtual int incr_height() const ; // average height of an item
// These only need to be done by subclass if you want a multi-browser: // These only need to be done by subclass if you want a multi-browser:
virtual void item_select(void *item,int val=1); virtual void item_select(void *item,int val=1);
virtual int item_selected(void *item) const ; virtual int item_selected(void *item) const ;
@@ -197,7 +195,7 @@ protected:
*/ */
void redraw_lines() { damage(FL_DAMAGE_SCROLL); } // redraw all of them void redraw_lines() { damage(FL_DAMAGE_SCROLL); } // redraw all of them
void bbox(int &X,int &Y,int &W,int &H) const; void bbox(int &X,int &Y,int &W,int &H) const;
int leftedge() const; // x position after scrollbar & border int leftedge() const; // x position after scrollbar & border
void *find_item(int ypos); // item under mouse void *find_item(int ypos); // item under mouse
void draw(); void draw();
@@ -250,13 +248,13 @@ public:
- bit 3-31: reserved for future use - bit 3-31: reserved for future use
*/ */
enum { // values for has_scrollbar() enum { // values for has_scrollbar()
HORIZONTAL = 1, ///< Only show horizontal scrollbar. HORIZONTAL = 1, ///< Only show horizontal scrollbar.
VERTICAL = 2, ///< Only show vertical scrollbar. VERTICAL = 2, ///< Only show vertical scrollbar.
BOTH = 3, ///< Show both scrollbars. (default) BOTH = 3, ///< Show both scrollbars. (default)
ALWAYS_ON = 4, ///< Specified scrollbar(s) should 'always' be shown (to be used with HORIZONTAL/VERTICAL) ALWAYS_ON = 4, ///< Specified scrollbar(s) should 'always' be shown (to be used with HORIZONTAL/VERTICAL)
HORIZONTAL_ALWAYS = 5, ///< Horizontal scrollbar always on. HORIZONTAL_ALWAYS = 5, ///< Horizontal scrollbar always on.
VERTICAL_ALWAYS = 6, ///< Vertical scrollbar always on. VERTICAL_ALWAYS = 6, ///< Vertical scrollbar always on.
BOTH_ALWAYS = 7 ///< Both scrollbars always on. BOTH_ALWAYS = 7 ///< Both scrollbars always on.
}; };
/** /**
Returns the current scrollbar mode, see Fl_Browser_::has_scrollbar(uchar) Returns the current scrollbar mode, see Fl_Browser_::has_scrollbar(uchar)
@@ -379,7 +377,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Button header file for the Fast Light Tool Kit (FLTK). // Button header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2014 by Bill Spitzak and others. // Copyright 1998-2014 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -27,13 +25,13 @@
#endif #endif
// values for type() // values for type()
#define FL_NORMAL_BUTTON 0 /**< value() will be set to 1 during the press of the button and #define FL_NORMAL_BUTTON 0 /**< value() will be set to 1 during the press of the button and
reverts back to 0 when the button is released */ reverts back to 0 when the button is released */
#define FL_TOGGLE_BUTTON 1 ///< value() toggles between 0 and 1 at every click of the button #define FL_TOGGLE_BUTTON 1 ///< value() toggles between 0 and 1 at every click of the button
#define FL_RADIO_BUTTON (FL_RESERVED_TYPE+2) /**< is set to 1 at button press, and all other #define FL_RADIO_BUTTON (FL_RESERVED_TYPE+2) /**< is set to 1 at button press, and all other
buttons in the same group with <tt>type() == FL_RADIO_BUTTON</tt> buttons in the same group with <tt>type() == FL_RADIO_BUTTON</tt>
are set to zero.*/ are set to zero.*/
#define FL_HIDDEN_BUTTON 3 ///< for Forms compatibility #define FL_HIDDEN_BUTTON 3 ///< for Forms compatibility
extern FL_EXPORT Fl_Shortcut fl_old_shortcut(const char*); extern FL_EXPORT Fl_Shortcut fl_old_shortcut(const char*);
@@ -59,7 +57,7 @@ class Fl_Widget_Tracker;
\li \c FL_TOGGLE_BUTTON: value() is inverted after button press. \li \c FL_TOGGLE_BUTTON: value() is inverted after button press.
\li \c FL_RADIO_BUTTON: value() is set to 1 after button press, and all other \li \c FL_RADIO_BUTTON: value() is set to 1 after button press, and all other
buttons in the current group with <tt>type() == FL_RADIO_BUTTON</tt> buttons in the current group with <tt>type() == FL_RADIO_BUTTON</tt>
are set to zero. are set to zero.
\todo Refactor the doxygen comments for Fl_Button when() documentation. \todo Refactor the doxygen comments for Fl_Button when() documentation.
@@ -70,7 +68,7 @@ class Fl_Widget_Tracker;
clicks the button, or when a shortcut is typed. clicks the button, or when a shortcut is typed.
\li \c FL_WHEN_CHANGED: The callback is done each time the value() changes \li \c FL_WHEN_CHANGED: The callback is done each time the value() changes
(when the user pushes and releases the button, and as the mouse is (when the user pushes and releases the button, and as the mouse is
dragged around in and out of the button). dragged around in and out of the button).
*/ */
class FL_EXPORT Fl_Button : public Fl_Widget { class FL_EXPORT Fl_Button : public Fl_Widget {
@@ -170,7 +168,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Main header file for the Fast Light Tool Kit (FLTK). // Main header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2016 by Bill Spitzak and others. // Copyright 1998-2016 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -48,33 +46,33 @@ public:
Fl_Cairo_State() : cc_(0), own_cc_(false), autolink_(false), window_(0), gc_(0) {} Fl_Cairo_State() : cc_(0), own_cc_(false), autolink_(false), window_(0), gc_(0) {}
// access attributes // access attributes
cairo_t* cc() const {return cc_;} ///< Gets the current cairo context cairo_t* cc() const {return cc_;} ///< Gets the current cairo context
bool autolink() const {return autolink_;} ///< Gets the autolink option. See Fl::cairo_autolink_context(bool) bool autolink() const {return autolink_;} ///< Gets the autolink option. See Fl::cairo_autolink_context(bool)
/** Sets the current cairo context. /** Sets the current cairo context.
\p own == \e true (the default) indicates that the cairo context \p c \p own == \e true (the default) indicates that the cairo context \p c
will be deleted by FLTK internally when another cc is set later. will be deleted by FLTK internally when another cc is set later.
\p own == \e false indicates cc deletion is handled externally \p own == \e false indicates cc deletion is handled externally
by the user program. by the user program.
*/ */
void cc(cairo_t* c, bool own=true) { void cc(cairo_t* c, bool own=true) {
if (cc_ && own_cc_) cairo_destroy(cc_); if (cc_ && own_cc_) cairo_destroy(cc_);
cc_=c; cc_=c;
if (!cc_) window_=0; if (!cc_) window_=0;
own_cc_=own; own_cc_=own;
} }
void autolink(bool b); ///< Sets the autolink option, only available with --enable-cairoext void autolink(bool b); ///< Sets the autolink option, only available with --enable-cairoext
void window(void* w) {window_=w;} ///< Sets the window \p w to keep track on void window(void* w) {window_=w;} ///< Sets the window \p w to keep track on
void* window() const {return window_;} ///< Gets the last window attached to a cc void* window() const {return window_;} ///< Gets the last window attached to a cc
void gc(void* c) {gc_=c;} ///< Sets the gc \p c to keep track on void gc(void* c) {gc_=c;} ///< Sets the gc \p c to keep track on
void* gc() const {return gc_;} ///< Gets the last gc attached to a cc void* gc() const {return gc_;} ///< Gets the last gc attached to a cc
private: private:
cairo_t * cc_; // contains the unique autoupdated cairo context cairo_t * cc_; // contains the unique autoupdated cairo context
bool own_cc_; // indicates whether we must delete the cc, useful for internal cleanup bool own_cc_; // indicates whether we must delete the cc, useful for internal cleanup
bool autolink_; // false by default, prevents the automatic cairo mapping on fltk windows bool autolink_; // false by default, prevents the automatic cairo mapping on fltk windows
// for custom cairo implementations. // for custom cairo implementations.
void* window_, *gc_; // for keeping track internally of last win+gc treated void* window_, *gc_; // for keeping track internally of last win+gc treated
}; };
@@ -82,7 +80,3 @@ private:
# endif // FLTK_HAVE_CAIRO # endif // FLTK_HAVE_CAIRO
#endif // FL_CAIRO_H #endif // FL_CAIRO_H
//
// End of "$Id$" .
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Main header file for the Fast Light Tool Kit (FLTK). // Main header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2018 by Bill Spitzak and others. // Copyright 1998-2018 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -62,7 +60,7 @@ protected:
if (draw_cb_) { // call the Cairo draw callback if (draw_cb_) { // call the Cairo draw callback
// manual method ? if yes explicitly get a cairo_context here // manual method ? if yes explicitly get a cairo_context here
if (!Fl::cairo_autolink_context()) if (!Fl::cairo_autolink_context())
Fl::cairo_make_current(this); Fl::cairo_make_current(this);
draw_cb_(this, Fl::cairo_cc()); draw_cb_(this, Fl::cairo_cc());
// flush cairo drawings: necessary at least for Windows // flush cairo drawings: necessary at least for Windows
cairo_surface_t *s = cairo_get_target(Fl::cairo_cc()); cairo_surface_t *s = cairo_get_target(Fl::cairo_cc());
@@ -87,7 +85,3 @@ private:
# endif // FLTK_HAVE_CAIRO # endif // FLTK_HAVE_CAIRO
#endif // FL_CAIRO_WINDOW_H #endif // FL_CAIRO_WINDOW_H
//
// End of "$Id$" .
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Forms chart header file for the Fast Light Tool Kit (FLTK). // Forms chart header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -27,24 +25,24 @@
#endif #endif
// values for type() // values for type()
#define FL_BAR_CHART 0 /**< type() for Bar Chart variant */ #define FL_BAR_CHART 0 /**< type() for Bar Chart variant */
#define FL_HORBAR_CHART 1 /**< type() for Horizontal Bar Chart variant */ #define FL_HORBAR_CHART 1 /**< type() for Horizontal Bar Chart variant */
#define FL_LINE_CHART 2 /**< type() for Line Chart variant */ #define FL_LINE_CHART 2 /**< type() for Line Chart variant */
#define FL_FILL_CHART 3 /**< type() for Fill Line Chart variant */ #define FL_FILL_CHART 3 /**< type() for Fill Line Chart variant */
#define FL_SPIKE_CHART 4 /**< type() for Spike Chart variant */ #define FL_SPIKE_CHART 4 /**< type() for Spike Chart variant */
#define FL_PIE_CHART 5 /**< type() for Pie Chart variant */ #define FL_PIE_CHART 5 /**< type() for Pie Chart variant */
#define FL_SPECIALPIE_CHART 6 /**< type() for Special Pie Chart variant */ #define FL_SPECIALPIE_CHART 6 /**< type() for Special Pie Chart variant */
#define FL_FILLED_CHART FL_FILL_CHART /**< for compatibility */ #define FL_FILLED_CHART FL_FILL_CHART /**< for compatibility */
#define FL_CHART_MAX 128 /**< max entries per chart */ #define FL_CHART_MAX 128 /**< max entries per chart */
#define FL_CHART_LABEL_MAX 18 /**< max label length for entry */ #define FL_CHART_LABEL_MAX 18 /**< max label length for entry */
/** For internal use only */ /** For internal use only */
struct FL_CHART_ENTRY { struct FL_CHART_ENTRY {
float val; /**< For internal use only. */ float val; /**< For internal use only. */
unsigned col; /**< For internal use only. */ unsigned col; /**< For internal use only. */
char str[FL_CHART_LABEL_MAX+1]; /**< For internal use only. */ char str[FL_CHART_LABEL_MAX+1]; /**< For internal use only. */
}; };
/** /**
@@ -145,7 +143,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Fl_Check_Browser header file for the Fast Light Tool Kit (FLTK). // Fl_Check_Browser header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -55,11 +53,11 @@ public:
#ifndef FL_DOXYGEN #ifndef FL_DOXYGEN
/** For internal use only. */ /** For internal use only. */
struct cb_item { struct cb_item {
cb_item *next; /**< For internal use only. */ cb_item *next; /**< For internal use only. */
cb_item *prev; /**< For internal use only. */ cb_item *prev; /**< For internal use only. */
char checked; /**< For internal use only. */ char checked; /**< For internal use only. */
char selected; /**< For internal use only. */ char selected; /**< For internal use only. */
char *text; /**< For internal use only. */ char *text; /**< For internal use only. */
}; };
#endif // !FL_DOXYGEN #endif // !FL_DOXYGEN
@@ -81,7 +79,7 @@ public:
~Fl_Check_Browser() { clear(); } ~Fl_Check_Browser() { clear(); }
int add(char *s); // add an (unchecked) item int add(char *s); // add an (unchecked) item
int add(char *s, int b); // add an item and set checked int add(char *s, int b); // add an item and set checked
// both return the new nitems() // both return the new nitems()
int remove(int item); // delete an item. Returns nitems() int remove(int item); // delete an item. Returns nitems()
// inline const char * methods to avoid breaking binary compatibility... // inline const char * methods to avoid breaking binary compatibility...
@@ -114,7 +112,3 @@ public:
#endif // Fl_Check_Browser_H #endif // Fl_Check_Browser_H
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Check button header file for the Fast Light Tool Kit (FLTK). // Check button header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2014 by Bill Spitzak and others. // Copyright 1998-2014 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
#ifndef Fl_Check_Button_H #ifndef Fl_Check_Button_H
@@ -33,7 +31,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Choice header file for the Fast Light Tool Kit (FLTK). // Choice header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -122,7 +120,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Clock header file for the Fast Light Tool Kit (FLTK). // Clock header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2017 by Bill Spitzak and others. // Copyright 1998-2017 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -30,9 +28,9 @@
// Please change doxygen documentation below (class Fl_Clock_Output) // Please change doxygen documentation below (class Fl_Clock_Output)
// accordingly as well when changing the following type values: // accordingly as well when changing the following type values:
#define FL_SQUARE_CLOCK 0 /**< type() of Square Clock variant */ #define FL_SQUARE_CLOCK 0 /**< type() of Square Clock variant */
#define FL_ROUND_CLOCK 1 /**< type() of Round Clock variant */ #define FL_ROUND_CLOCK 1 /**< type() of Round Clock variant */
#define FL_ANALOG_CLOCK FL_SQUARE_CLOCK /**< An analog clock is square */ #define FL_ANALOG_CLOCK FL_SQUARE_CLOCK /**< An analog clock is square */
#define FL_DIGITAL_CLOCK FL_SQUARE_CLOCK /**< Not yet implemented */ #define FL_DIGITAL_CLOCK FL_SQUARE_CLOCK /**< Not yet implemented */
// fabien: Please keep the horizontal formatting of both images in class desc, // fabien: Please keep the horizontal formatting of both images in class desc,
@@ -57,10 +55,10 @@
Values for clock type() (\#include \<FL/Clock.H\>): Values for clock type() (\#include \<FL/Clock.H\>):
\code \code
#define FL_SQUARE_CLOCK 0 // Square Clock variant #define FL_SQUARE_CLOCK 0 // Square Clock variant
#define FL_ROUND_CLOCK 1 // Round Clock variant #define FL_ROUND_CLOCK 1 // Round Clock variant
#define FL_ANALOG_CLOCK FL_SQUARE_CLOCK // An analog clock is square #define FL_ANALOG_CLOCK FL_SQUARE_CLOCK // An analog clock is square
#define FL_DIGITAL_CLOCK FL_SQUARE_CLOCK // Not yet implemented #define FL_DIGITAL_CLOCK FL_SQUARE_CLOCK // Not yet implemented
\endcode \endcode
*/ */
@@ -76,7 +74,7 @@ public:
Fl_Clock_Output(int X, int Y, int W, int H, const char *L = 0); Fl_Clock_Output(int X, int Y, int W, int H, const char *L = 0);
void value(ulong v); // set to this Unix time void value(ulong v); // set to this Unix time
void value(int H, int m, int s); void value(int H, int m, int s);
@@ -108,9 +106,9 @@ public:
/** /**
Returns the shadow drawing mode of the hands. Returns the shadow drawing mode of the hands.
\returns shadow drawing mode of the hands \returns shadow drawing mode of the hands
\retval 0 no shadows \retval 0 no shadows
\retval 1 draw shadows of hands (default) \retval 1 draw shadows of hands (default)
*/ */
int shadow() const {return shadow_;} int shadow() const {return shadow_;}
@@ -124,7 +122,7 @@ public:
The default is to draw the shadows (1). The default is to draw the shadows (1).
\param[in] mode 1 = shadows (default), 0 = no shadows \param[in] mode 1 = shadows (default), 0 = no shadows
*/ */
void shadow(int mode) { shadow_ = mode ? 1 : 0; } void shadow(int mode) { shadow_ = mode ? 1 : 0; }
}; };
@@ -163,7 +161,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Color chooser header file for the Fast Light Tool Kit (FLTK). // Color chooser header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2019 by Bill Spitzak and others. // Copyright 1998-2019 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/** \file /** \file
@@ -190,7 +188,3 @@ FL_EXPORT int fl_color_chooser(const char* name, double& r, double& g, double& b
FL_EXPORT int fl_color_chooser(const char* name, uchar& r, uchar& g, uchar& b, int m=-1); FL_EXPORT int fl_color_chooser(const char* name, uchar& r, uchar& g, uchar& b, int m=-1);
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Copy-to-clipboard code for the Fast Light Tool Kit (FLTK). // Copy-to-clipboard code for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2014 by Bill Spitzak and others. // Copyright 1998-2014 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
#ifndef Fl_Copy_Surface_H #ifndef Fl_Copy_Surface_H
@@ -108,7 +106,3 @@ protected:
*/ */
#endif // Fl_Copy_Surface_H #endif // Fl_Copy_Surface_H
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Counter header file for the Fast Light Tool Kit (FLTK). // Counter header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -29,8 +27,8 @@
#endif #endif
// values for type(): // values for type():
#define FL_NORMAL_COUNTER 0 /**< type() for counter with fast buttons */ #define FL_NORMAL_COUNTER 0 /**< type() for counter with fast buttons */
#define FL_SIMPLE_COUNTER 1 /**< type() for counter without fast buttons */ #define FL_SIMPLE_COUNTER 1 /**< type() for counter without fast buttons */
/** /**
Controls a single floating point value with button (or keyboard) arrows. Controls a single floating point value with button (or keyboard) arrows.
@@ -109,7 +107,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Definition of classes Fl_Surface_Device, Fl_Display_Device // Definition of classes Fl_Surface_Device, Fl_Display_Device
// for the Fast Light Tool Kit (FLTK). // for the Fast Light Tool Kit (FLTK).
// //
@@ -10,11 +8,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/** \file Fl_Device.H /** \file Fl_Device.H
@@ -130,7 +128,3 @@ public:
}; };
#endif // Fl_Device_H #endif // Fl_Device_H
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Dial header file for the Fast Light Tool Kit (FLTK). // Dial header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -27,9 +25,9 @@
#endif #endif
// values for type(): // values for type():
#define FL_NORMAL_DIAL 0 /**< type() for dial variant with dot */ #define FL_NORMAL_DIAL 0 /**< type() for dial variant with dot */
#define FL_LINE_DIAL 1 /**< type() for dial variant with line */ #define FL_LINE_DIAL 1 /**< type() for dial variant with line */
#define FL_FILL_DIAL 2 /**< type() for dial variant with filled arc */ #define FL_FILL_DIAL 2 /**< type() for dial variant with filled arc */
/** /**
The Fl_Dial widget provides a circular dial to control a The Fl_Dial widget provides a circular dial to control a
@@ -82,7 +80,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Double-buffered window header file for the Fast Light Tool Kit (FLTK). // Double-buffered window header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -65,7 +63,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
/* /*
* "$Id$"
*
* Windows DLL export . * Windows DLL export .
* *
* Copyright 1998-2018 by Bill Spitzak and others. * Copyright 1998-2018 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
* the file "COPYING" which should have been included with this file. If this * the file "COPYING" which should have been included with this file. If this
* file is missing or damaged, see the license at: * file is missing or damaged, see the license at:
* *
* http://www.fltk.org/COPYING.php * https://www.fltk.org/COPYING.php
* *
* Please report all bugs and problems on the following page: * Please see the following page on how to report bugs and issues:
* *
* http://www.fltk.org/str.php * https://www.fltk.org/bugs.php
*/ */
#ifndef Fl_Export_H #ifndef Fl_Export_H
@@ -25,9 +23,9 @@
# if defined(FL_DLL) # if defined(FL_DLL)
# ifdef FL_LIBRARY # ifdef FL_LIBRARY
# define FL_EXPORT __declspec(dllexport) # define FL_EXPORT __declspec(dllexport)
# else # else
# define FL_EXPORT __declspec(dllimport) # define FL_EXPORT __declspec(dllimport)
# endif /* FL_LIBRARY */ # endif /* FL_LIBRARY */
# elif __GNUC__ >= 4 # elif __GNUC__ >= 4
# define FL_EXPORT __attribute__ ((visibility ("default"))) # define FL_EXPORT __attribute__ ((visibility ("default")))
@@ -36,7 +34,3 @@
# endif /* FL_DLL */ # endif /* FL_DLL */
#endif /* !Fl_Export_H */ #endif /* !Fl_Export_H */
/*
* End of "$Id$".
*/

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// FileBrowser definitions. // FileBrowser definitions.
// //
// Copyright 1999-2010 by Michael Sweet. // Copyright 1999-2010 by Michael Sweet.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -38,16 +36,16 @@
/** The Fl_File_Browser widget displays a list of filenames, optionally with file-specific icons. */ /** The Fl_File_Browser widget displays a list of filenames, optionally with file-specific icons. */
class FL_EXPORT Fl_File_Browser : public Fl_Browser { class FL_EXPORT Fl_File_Browser : public Fl_Browser {
int filetype_; int filetype_;
const char *directory_; const char *directory_;
uchar iconsize_; uchar iconsize_;
const char *pattern_; const char *pattern_;
int full_height() const; int full_height() const;
int item_height(void *) const; int item_height(void *) const;
int item_width(void *) const; int item_width(void *) const;
void item_draw(void *, int, int, int, int) const; void item_draw(void *, int, int, int, int) const;
int incr_height() const { return (item_height(0)); } int incr_height() const { return (item_height(0)); }
public: public:
enum { FILES, DIRECTORIES }; enum { FILES, DIRECTORIES };
@@ -59,22 +57,22 @@ public:
Fl_File_Browser(int, int, int, int, const char * = 0); Fl_File_Browser(int, int, int, int, const char * = 0);
/** Sets or gets the size of the icons. The default size is 20 pixels. */ /** Sets or gets the size of the icons. The default size is 20 pixels. */
uchar iconsize() const { return (iconsize_); }; uchar iconsize() const { return (iconsize_); };
/** Sets or gets the size of the icons. The default size is 20 pixels. */ /** Sets or gets the size of the icons. The default size is 20 pixels. */
void iconsize(uchar s) { iconsize_ = s; redraw(); }; void iconsize(uchar s) { iconsize_ = s; redraw(); };
/** /**
Sets or gets the filename filter. The pattern matching uses Sets or gets the filename filter. The pattern matching uses
the fl_filename_match() the fl_filename_match()
function in FLTK. function in FLTK.
*/ */
void filter(const char *pattern); void filter(const char *pattern);
/** /**
Sets or gets the filename filter. The pattern matching uses Sets or gets the filename filter. The pattern matching uses
the fl_filename_match() the fl_filename_match()
function in FLTK. function in FLTK.
*/ */
const char *filter() const { return (pattern_); }; const char *filter() const { return (pattern_); };
/** /**
Loads the specified directory into the browser. If icons have been Loads the specified directory into the browser. If icons have been
@@ -83,10 +81,10 @@ public:
<P>The sort argument specifies a sort function to be used with <P>The sort argument specifies a sort function to be used with
fl_filename_list(). fl_filename_list().
*/ */
int load(const char *directory, Fl_File_Sort_F *sort = fl_numericsort); int load(const char *directory, Fl_File_Sort_F *sort = fl_numericsort);
Fl_Fontsize textsize() const { return Fl_Browser::textsize(); }; Fl_Fontsize textsize() const { return Fl_Browser::textsize(); };
void textsize(Fl_Fontsize s) { Fl_Browser::textsize(s); iconsize_ = (uchar)(3 * s / 2); }; void textsize(Fl_Fontsize s) { Fl_Browser::textsize(s); iconsize_ = (uchar)(3 * s / 2); };
/** /**
Sets or gets the file browser type, FILES or Sets or gets the file browser type, FILES or
@@ -94,18 +92,14 @@ public:
files and directories are shown. Otherwise only directories are files and directories are shown. Otherwise only directories are
shown. shown.
*/ */
int filetype() const { return (filetype_); }; int filetype() const { return (filetype_); };
/** /**
Sets or gets the file browser type, FILES or Sets or gets the file browser type, FILES or
DIRECTORIES. When set to FILES, both DIRECTORIES. When set to FILES, both
files and directories are shown. Otherwise only directories are files and directories are shown. Otherwise only directories are
shown. shown.
*/ */
void filetype(int t) { filetype_ = t; }; void filetype(int t) { filetype_ = t; };
}; };
#endif // !_Fl_File_Browser_H_ #endif // !_Fl_File_Browser_H_
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Fl_File_Chooser dialog for the Fast Light Tool Kit (FLTK). // Fl_File_Chooser dialog for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2015 by Bill Spitzak and others. // Copyright 1998-2015 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
// ======================================================================= // =======================================================================
// DO NOT EDIT FL/Fl_File_Chooser.H and src/Fl_File_Chooser.cxx !!! // DO NOT EDIT FL/Fl_File_Chooser.H and src/Fl_File_Chooser.cxx !!!
@@ -239,7 +237,3 @@ FL_EXPORT char *fl_file_chooser(const char *message,const char *pat,const char *
FL_EXPORT void fl_file_chooser_callback(void (*cb)(const char*)); FL_EXPORT void fl_file_chooser_callback(void (*cb)(const char*));
FL_EXPORT void fl_file_chooser_ok_label(const char*l); FL_EXPORT void fl_file_chooser_ok_label(const char*l);
#endif #endif
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Fl_File_Icon definitions. // Fl_File_Icon definitions.
// //
// Copyright 1999-2010 by Michael Sweet. // Copyright 1999-2010 by Michael Sweet.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -33,7 +31,7 @@
// Special color value for the icon color. // Special color value for the icon color.
// //
# define FL_ICON_COLOR (Fl_Color)0xffffffff /**< icon color [background?]*/ # define FL_ICON_COLOR (Fl_Color)0xffffffff /**< icon color [background?]*/
// //
@@ -44,50 +42,50 @@
The Fl_File_Icon class manages icon images that can be used The Fl_File_Icon class manages icon images that can be used
as labels in other widgets and as icons in the FileBrowser widget. as labels in other widgets and as icons in the FileBrowser widget.
*/ */
class FL_EXPORT Fl_File_Icon { //// Icon data class FL_EXPORT Fl_File_Icon { //// Icon data
static Fl_File_Icon *first_; // Pointer to first icon/filetype static Fl_File_Icon *first_; // Pointer to first icon/filetype
Fl_File_Icon *next_; // Pointer to next icon/filetype Fl_File_Icon *next_; // Pointer to next icon/filetype
const char *pattern_; // Pattern string const char *pattern_; // Pattern string
int type_; // Match only if directory or file? int type_; // Match only if directory or file?
int num_data_; // Number of data elements int num_data_; // Number of data elements
int alloc_data_; // Number of allocated elements int alloc_data_; // Number of allocated elements
short *data_; // Icon data short *data_; // Icon data
public: public:
enum // File types enum // File types
{ {
ANY, // Any kind of file ANY, // Any kind of file
PLAIN, // Only plain files PLAIN, // Only plain files
FIFO, // Only named pipes FIFO, // Only named pipes
DEVICE, // Only character and block devices DEVICE, // Only character and block devices
LINK, // Only symbolic links LINK, // Only symbolic links
DIRECTORY // Only directories DIRECTORY // Only directories
}; };
enum // Data opcodes enum // Data opcodes
{ {
END, // End of primitive/icon END, // End of primitive/icon
COLOR, // Followed by color value (2 shorts) COLOR, // Followed by color value (2 shorts)
LINE, // Start of line LINE, // Start of line
CLOSEDLINE, // Start of closed line CLOSEDLINE, // Start of closed line
POLYGON, // Start of polygon POLYGON, // Start of polygon
OUTLINEPOLYGON, // Followed by outline color (2 shorts) OUTLINEPOLYGON, // Followed by outline color (2 shorts)
VERTEX // Followed by scaled X,Y VERTEX // Followed by scaled X,Y
}; };
Fl_File_Icon(const char *p, int t, int nd = 0, short *d = 0); Fl_File_Icon(const char *p, int t, int nd = 0, short *d = 0);
~Fl_File_Icon(); ~Fl_File_Icon();
short *add(short d); short *add(short d);
/** /**
Adds a color value to the icon array, returning a pointer to it. Adds a color value to the icon array, returning a pointer to it.
\param[in] c color value \param[in] c color value
*/ */
short *add_color(Fl_Color c) short *add_color(Fl_Color c)
{ short *d = add((short)COLOR); add((short)(c >> 16)); add((short)c); return (d); } { short *d = add((short)COLOR); add((short)(c >> 16)); add((short)c); return (d); }
/** /**
Adds a vertex value to the icon array, returning a pointer to it. Adds a vertex value to the icon array, returning a pointer to it.
@@ -95,8 +93,8 @@ class FL_EXPORT Fl_File_Icon { //// Icon data
The origin (0.0) is in the lower-lefthand corner of the icon. The origin (0.0) is in the lower-lefthand corner of the icon.
\param[in] x, y vertex coordinates \param[in] x, y vertex coordinates
*/ */
short *add_vertex(int x, int y) short *add_vertex(int x, int y)
{ short *d = add((short)VERTEX); add((short)x); add((short)y); return (d); } { short *d = add((short)VERTEX); add((short)x); add((short)y); return (d); }
/** /**
Adds a vertex value to the icon array, returning a pointer to it. Adds a vertex value to the icon array, returning a pointer to it.
@@ -104,30 +102,30 @@ class FL_EXPORT Fl_File_Icon { //// Icon data
The origin (0.0) is in the lower-lefthand corner of the icon. The origin (0.0) is in the lower-lefthand corner of the icon.
\param[in] x, y vertex coordinates \param[in] x, y vertex coordinates
*/ */
short *add_vertex(float x, float y) short *add_vertex(float x, float y)
{ short *d = add((short)VERTEX); add((short)(x * 10000.0)); { short *d = add((short)VERTEX); add((short)(x * 10000.0));
add((short)(y * 10000.0)); return (d); } add((short)(y * 10000.0)); return (d); }
/** Clears all icon data from the icon.*/ /** Clears all icon data from the icon.*/
void clear() { num_data_ = 0; } void clear() { num_data_ = 0; }
void draw(int x, int y, int w, int h, Fl_Color ic, int active = 1); void draw(int x, int y, int w, int h, Fl_Color ic, int active = 1);
void label(Fl_Widget *w); void label(Fl_Widget *w);
static void labeltype(const Fl_Label *o, int x, int y, int w, int h, Fl_Align a); static void labeltype(const Fl_Label *o, int x, int y, int w, int h, Fl_Align a);
void load(const char *f); void load(const char *f);
int load_fti(const char *fti); int load_fti(const char *fti);
int load_image(const char *i); int load_image(const char *i);
/** Returns next file icon object. See Fl_File_Icon::first() */ /** Returns next file icon object. See Fl_File_Icon::first() */
Fl_File_Icon *next() { return (next_); } Fl_File_Icon *next() { return (next_); }
/** Returns the filename matching pattern for the icon.*/ /** Returns the filename matching pattern for the icon.*/
const char *pattern() { return (pattern_); } const char *pattern() { return (pattern_); }
/** Returns the number of words of data used by the icon.*/ /** Returns the number of words of data used by the icon.*/
int size() { return (num_data_); } int size() { return (num_data_); }
/** /**
Returns the filetype associated with the icon, which can be one of the Returns the filetype associated with the icon, which can be one of the
@@ -140,20 +138,16 @@ class FL_EXPORT Fl_File_Icon { //// Icon data
\li Fl_File_Icon::LINK, symbolic links. \li Fl_File_Icon::LINK, symbolic links.
\li Fl_File_Icon::DIRECTORY, directories. \li Fl_File_Icon::DIRECTORY, directories.
*/ */
int type() { return (type_); } int type() { return (type_); }
/** Returns the data array for the icon.*/ /** Returns the data array for the icon.*/
short *value() { return (data_); } short *value() { return (data_); }
static Fl_File_Icon *find(const char *filename, int filetype = ANY); static Fl_File_Icon *find(const char *filename, int filetype = ANY);
/** Returns a pointer to the first icon in the list.*/ /** Returns a pointer to the first icon in the list.*/
static Fl_File_Icon *first() { return (first_); } static Fl_File_Icon *first() { return (first_); }
static void load_system_icons(void); static void load_system_icons(void);
}; };
#endif // !_Fl_Fl_File_Icon_H_ #endif // !_Fl_Fl_File_Icon_H_
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// File_Input header file for the Fast Light Tool Kit (FLTK). // File_Input header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -10,11 +8,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -46,14 +44,14 @@
*/ */
class FL_EXPORT Fl_File_Input : public Fl_Input { class FL_EXPORT Fl_File_Input : public Fl_Input {
char ok_entry_; char ok_entry_;
uchar down_box_; uchar down_box_;
short buttons_[200]; short buttons_[200];
short pressed_; short pressed_;
void draw_buttons(); void draw_buttons();
int handle_button(int event); int handle_button(int event);
void update_buttons(); void update_buttons();
public: public:
@@ -66,9 +64,9 @@ protected:
public: public:
/** Gets the box type used for the navigation bar. */ /** Gets the box type used for the navigation bar. */
Fl_Boxtype down_box() const { return (Fl_Boxtype)down_box_; } Fl_Boxtype down_box() const { return (Fl_Boxtype)down_box_; }
/** Sets the box type to use for the navigation bar. */ /** Sets the box type to use for the navigation bar. */
void down_box(Fl_Boxtype b) { down_box_ = b; } void down_box(Fl_Boxtype b) { down_box_ = b; }
/** /**
Gets the current error color. Gets the current error color.
@@ -79,7 +77,7 @@ public:
\deprecated Will be removed in FLTK 1.5.0 or higher. \deprecated Will be removed in FLTK 1.5.0 or higher.
\todo Remove Fl_File_Input::errorcolor() in FLTK 1.5.0 or higher. \todo Remove Fl_File_Input::errorcolor() in FLTK 1.5.0 or higher.
*/ */
Fl_Color errorcolor() const { return FL_RED; } Fl_Color errorcolor() const { return FL_RED; }
/** /**
Sets the current error color to \p c. Sets the current error color to \p c.
@@ -89,21 +87,16 @@ public:
\deprecated Will be removed in FLTK 1.5.0 or higher. \deprecated Will be removed in FLTK 1.5.0 or higher.
\todo Remove Fl_File_Input::errorcolor(Fl_Color) in FLTK 1.5.0 or higher. \todo Remove Fl_File_Input::errorcolor(Fl_Color) in FLTK 1.5.0 or higher.
*/ */
void errorcolor(Fl_Color c) {} void errorcolor(Fl_Color c) {}
int value(const char *str); int value(const char *str);
int value(const char *str, int len); int value(const char *str, int len);
/** /**
Returns the current value, which is a pointer to an internal buffer Returns the current value, which is a pointer to an internal buffer
and is valid only until the next event is handled. and is valid only until the next event is handled.
*/ */
const char *value() { return Fl_Input_::value(); } const char *value() { return Fl_Input_::value(); }
}; };
#endif // !Fl_File_Input_H #endif // !Fl_File_Input_H
//
// End of "$Id$".
//

View File

@@ -1,6 +1,4 @@
// //
// "$Id$"
//
// Filled dial header file for the Fast Light Tool Kit (FLTK). // Filled dial header file for the Fast Light Tool Kit (FLTK).
// //
// Copyright 1998-2010 by Bill Spitzak and others. // Copyright 1998-2010 by Bill Spitzak and others.
@@ -9,11 +7,11 @@
// the file "COPYING" which should have been included with this file. If this // the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at: // file is missing or damaged, see the license at:
// //
// http://www.fltk.org/COPYING.php // https://www.fltk.org/COPYING.php
// //
// Please report all bugs and problems on the following page: // Please see the following page on how to report bugs and issues:
// //
// http://www.fltk.org/str.php // https://www.fltk.org/bugs.php
// //
/* \file /* \file
@@ -32,7 +30,3 @@ public:
}; };
#endif #endif
//
// End of "$Id$".
//

Some files were not shown because too many files have changed in this diff Show More