From 9a528400f083b3761e0d54565ea1002604f5472a Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Tue, 4 Sep 2001 13:13:29 +0000 Subject: Doco updates. Add directory-only support to Fl_FileBrowser. Update button and menu drawing code for check and radio buttons. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1582 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- documentation/Fl_FileBrowser.html | 55 +++++++++--------- documentation/Fl_FileChooser.html | 110 ++++++++++++++++-------------------- documentation/Fl_FileIcon.html | 116 +++++++++++++++++--------------------- 3 files changed, 128 insertions(+), 153 deletions(-) (limited to 'documentation') diff --git a/documentation/Fl_FileBrowser.html b/documentation/Fl_FileBrowser.html index 4a0203298..2c9e1da00 100644 --- a/documentation/Fl_FileBrowser.html +++ b/documentation/Fl_FileBrowser.html @@ -1,76 +1,73 @@ - - FileBrowser - ESP Widget Set for FLTK - - - Widget Set Home Page - Widget Set Documentation - Download Widget Set - ESP Home Page - FLTK Home Page - - - - + -

class FileBrowser

+

class Fl_FileBrowser


Class Hierarchy

Include Files

Description

-

The FileBrowser widget displays a list of filenames, +

The Fl_FileBrowser widget displays a list of filenames, optionally with file-specific icons.

Methods

-

FileBrowser(int xx, int yy, int ww, int hh, const char *l = 0)

+

Fl_FileBrowser(int xx, int yy, int ww, int hh, const char *l = 0)

-

The constructor creates the FileBrowser widget at the specified +

The constructor creates the Fl_FileBrowser widget at the specified position and size. -

~FileBrowser()

+

~Fl_FileBrowser()

The destructor destroys the widget and frees all memory that has been allocated. -

void iconsize(uchar s)
+

void iconsize(uchar s)
uchar iconsize() const

Sets or gets the size of the icons. The default size is 20 pixels. -

void filter(const char *pattern)
+

void filter(const char *pattern)
const char *filter() const

Sets or gets the filename filter. The pattern matching uses the filename_match() function in FLTK. -

int load(const char *directory)

+

void filetype(int type)
+int filetype() const

+ +

Sets or gets the file browser type, FILES or +DIRECTORIES. When set to FILES, both +files and directories are shown. Otherwise only directories are +shown. + +

int load(const char *directory)

Loads the specified directory into the browser. If icons have been loaded then the correct icon is associated with each file in the list. diff --git a/documentation/Fl_FileChooser.html b/documentation/Fl_FileChooser.html index 6a3010702..13846c34d 100644 --- a/documentation/Fl_FileChooser.html +++ b/documentation/Fl_FileChooser.html @@ -1,72 +1,60 @@ - - FileChooser - ESP Widget Set for FLTK - - - Widget Set Home Page - Widget Set Documentation - Download Widget Set - ESP Home Page - FLTK Home Page - - - - + -

class FileChooser

+

class Fl_FileChooser


Class Hierarchy

Include Files

Description

-

The FileChooser widget displays a standard file selection +

The Fl_FileChooser widget displays a standard file selection dialog that supports various selection modes. -

FileChooser widget
+
Fl_FileChooser widget

Methods

-

FileChooser(const char *pathname, const char *pattern, +

Fl_FileChooser(const char *pathname, const char *pattern, int type, const char *title)

-

The constructor creates the FileChooser dialog pictured +

The constructor creates the Fl_FileChooser dialog pictured above. The pathname argument can be a directory name or a complete file name (in which case the corresponding file is highlighted in the list and in the filename input field.) @@ -84,86 +72,88 @@ in the list and in the filename input field.) or more existing files.

  • CREATE - allows the user to select a single, existing file or specify a new filename. +
  • DIRECTORY - allows the user to select a + single, existing directory.

    The title argument is used to set the title bar text for the -FileChooser window. +Fl_FileChooser window. -

    ~FileChooser()

    +

    ~Fl_FileChooser()

    Destroys the widget and frees all memory used by it. -

    void color(Fl_Color c)
    +

    void color(Fl_Color c)
    Fl_Color color()

    Sets or gets the background color of the FileBrowser list. -

    int count()

    +

    int count()

    Returns the number of selected files. -

    void directory(const char *pathname)
    +

    void directory(const char *pathname)
    const char *directory()

    Sets or gets the current directory. -

    void filter(const char *pattern)
    +

    void filter(const char *pattern)
    const char *filter()

    Sets or gets the current filename filter pattern. -

    void hide()

    +

    void hide()

    -

    Hides the FileChooser window. +

    Hides the Fl_FileChooser window. -

    void iconsize(uchar s)
    +

    void iconsize(uchar s)
    uchar iconsize()

    Sets or gets the size of the icons in the FileBrowser. By default the icon size is set to 1.5 times the textsize(). -

    void label(const char *l)
    +

    void label(const char *l)
    const char *label()

    -

    Sets or gets the title bar text for the FileChooser. +

    Sets or gets the title bar text for the Fl_FileChooser. -

    void rescan()

    +

    void rescan()

    Reloads the current directory in the FileBrowser. -

    void show()

    +

    void show()

    -

    Shows the FileChooser window. +

    Shows the Fl_FileChooser window. -

    void textcolor(Fl_Color c)
    +

    void textcolor(Fl_Color c)
    Fl_Color textcolor()

    Sets or gets the current FileBrowser text color. -

    void textfont(uchar f)
    +

    void textfont(uchar f)
    uchar textfont()

    Sets or gets the current FileBrowser text font. -

    void textsize(uchar s)
    +

    void textsize(uchar s)
    uchar textsize()

    Sets or gets the current FileBrowser text size. -

    void type(int t)
    +

    void type(int t)
    int type()

    -

    Sets or gets the current type of FileChooser. +

    Sets or gets the current type of Fl_FileChooser. -

    const char *value(const char *pathname)
    +

    const char *value(const char *pathname)
    const char *value(int file)
    const char *value()

    Sets or gets the current value of the selected file. -

    int visible()

    +

    int visible()

    -

    Returns 1 if the FileChooser window is visible. +

    Returns 1 if the Fl_FileChooser window is visible.


    diff --git a/documentation/Fl_FileIcon.html b/documentation/Fl_FileIcon.html index bd60fb93a..51c80f68c 100644 --- a/documentation/Fl_FileIcon.html +++ b/documentation/Fl_FileIcon.html @@ -1,38 +1,26 @@ - - FileIcon - ESP Widget Set for FLTK - - - Widget Set Home Page - Widget Set Documentation - Download Widget Set - ESP Home Page - FLTK Home Page - - - - + -

    class FileIcon

    +

    class Fl_FileIcon


    Class Hierarchy

      -FileIcon
      +Fl_FileIcon
       

    Include Files

      -#include "FileIcon.h"
      +#include <FL/Fl_FileIcon.H>
       

    Description

    -

    The FileIcon class manages icon images that can be +

    The Fl_FileIcon class manages icon images that can be used as labels in other widgets and as icons in the FileBrowser widget. @@ -40,47 +28,47 @@ widget.

    -

    FileIcon()

    +

    Fl_FileIcon()

    -

    The constructor creates a new FileIcon with the specified +

    The constructor creates a new Fl_FileIcon with the specified information. -

    ~FileIcon()

    +

    ~Fl_FileIcon()

    The destructor destroys the icon and frees all memory that has been allocated for it. -

    short *add(short d)

    +

    short *add(short d)

    Adds a keyword value to the icon array, returning a pointer to it. -

    short *add_color(short c)

    +

    short *add_color(short c)

    Adds a color value to the icon array, returning a pointer to it. -

    short *add_vertex(int x, int y)
    +

    short *add_vertex(int x, int y)
    short *add_vertex(float x, float y)

    Adds a vertex value to the icon array, returning a pointer to it. @@ -88,76 +76,76 @@ The integer version accepts coordinates from 0 to 10000, while the floating point version goes from 0.0 to 1.0. The origin (0.0) is in the lower-lefthand corner of the icon. -

    void clear()

    +

    void clear()

    Clears all icon data from the icon. -

    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)

    Draws the icon in the indicated area. -

    static FileIcon *find(const char *filename, int filetype = ANY);

    +

    static Fl_FileIcon *find(const char *filename, int filetype = ANY);

    Finds an icon that matches the given filename and file type. -

    static FileIcon *first()

    +

    static Fl_FileIcon *first()

    Returns a pointer to the first icon in the list. -

    void label(Fl_Widget *w)

    +

    void label(Fl_Widget *w)

    -

    Applies the icon to the widget, registering the FileIcon +

    Applies the icon to the widget, registering the Fl_FileIcon label type as needed. -

    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)

    The labeltype function for icons. -

    void load(const char *f)

    +

    void load(const char *f)

    Loads the specified icon image. The format is deduced from the filename. -

    void load_fti(const char *fti)

    +

    void load_fti(const char *fti)

    Loads an SGI icon file. -

    static void load_system_icons(void)

    +

    static void load_system_icons(void)

    Loads all system-defined icons. This call is useful when using the FileChooser widget and should be used when the application starts:

      -FileIcon::load_system_icons();
      +Fl_FileIcon::load_system_icons();
       
    -

    void load_xpm(const char *xpm)

    +

    void load_xpm(const char *xpm)

    Loads an XPM icon file. -

    const char *pattern()

    +

    const char *pattern()

    Returns the filename matching pattern for the icon. -

    int size()

    +

    int size()

    Returns the number of words of data used by the icon. -

    int type()

    +

    int type()

    Returns the filetype associated with the icon, which can be one of the following:

      -
    • FileIcon::ANY, any kind of file. -
    • FileIcon::PLAIN, plain files. -
    • FileIcon::FIFO, named pipes. -
    • FileIcon::DEVICE, character and block devices. -
    • FileIcon::LINK, symbolic links. -
    • FileIcon::DIRECTORY, directories. +
    • Fl_FileIcon::ANY, any kind of file. +
    • Fl_FileIcon::PLAIN, plain files. +
    • Fl_FileIcon::FIFO, named pipes. +
    • Fl_FileIcon::DEVICE, character and block devices. +
    • Fl_FileIcon::LINK, symbolic links. +
    • Fl_FileIcon::DIRECTORY, directories.
    -

    short *value()

    +

    short *value()

    Returns the data array for the icon. -- cgit v1.2.3