28#ifndef Fl_File_Chooser_H 
   29#define Fl_File_Chooser_H 
   31#include <FL/Fl_Double_Window.H> 
   35#include <FL/Fl_Group.H> 
   36#include <FL/Fl_Choice.H> 
   37#include <FL/Fl_Menu_Button.H> 
   38#include <FL/Fl_Button.H> 
   39#include <FL/Fl_Preferences.H> 
   40#include <FL/Fl_Tile.H> 
   41#include <FL/Fl_File_Browser.H> 
   43#include <FL/Fl_Check_Button.H> 
   44#include <FL/Fl_File_Input.H> 
   45#include <FL/Fl_Return_Button.H> 
   50  enum { SINGLE = 0, MULTI = 1, CREATE = 2, DIRECTORY = 4 }; 
 
   57  char preview_text_[2048]; 
 
   59  void favoritesButtonCB(); 
 
   66  void update_favorites(); 
 
   67  void update_preview(); 
 
   69  Fl_File_Chooser(
const char *d, 
const char *p, 
int t, 
const char *title);
 
   75  inline void cb_showChoice_i(
Fl_Choice*, 
void*);
 
   76  static void cb_showChoice(
Fl_Choice*, 
void*);
 
   83  inline void cb_newButton_i(
Fl_Button*, 
void*);
 
   84  static void cb_newButton(
Fl_Button*, 
void*);
 
   85  inline void cb__i(
Fl_Tile*, 
void*);
 
   86  static void cb_(
Fl_Tile*, 
void*);
 
  108  inline void cb_cancelButton_i(
Fl_Button*, 
void*);
 
  109  static void cb_cancelButton(
Fl_Button*, 
void*);
 
  115  inline void cb_favUpButton_i(
Fl_Button*, 
void*);
 
  116  static void cb_favUpButton(
Fl_Button*, 
void*);
 
  118  inline void cb_favDeleteButton_i(
Fl_Button*, 
void*);
 
  119  static void cb_favDeleteButton(
Fl_Button*, 
void*);
 
  121  inline void cb_favDownButton_i(
Fl_Button*, 
void*);
 
  122  static void cb_favDownButton(
Fl_Button*, 
void*);
 
  124  inline void cb_favCancelButton_i(
Fl_Button*, 
void*);
 
  125  static void cb_favCancelButton(
Fl_Button*, 
void*);
 
  137  void filter(
const char *p); 
 
  144  void label(
const char *l);
 
  145  const char * 
label();
 
  151  void showHidden(
int e); 
 
  152  void remove_hidden_files(); 
 
  155  void rescan_keep_filename(); 
 
  166  void * user_data() 
const;
 
  167  void user_data(
void *d);
 
  168  const char *value(
int f = 1); 
 
  169  void value(
const char *filename); 
 
 
  237FL_EXPORT 
char *fl_dir_chooser(
const char *message,
const char *fname,
int relative=0);
 
  238FL_EXPORT 
char *fl_file_chooser(
const char *message,
const char *pat,
const char *fname,
int relative=0);
 
  239FL_EXPORT 
void fl_file_chooser_callback(
void (*cb)(
const char*));
 
  240FL_EXPORT 
void fl_file_chooser_ok_label(
const char*l);
 
int Fl_Font
A font number is an index into the internal font table.
Definition Enumerations.H:884
unsigned int Fl_Color
An FLTK color value; see also Colors.
Definition Enumerations.H:941
int Fl_Fontsize
Size of a font in pixels.
Definition Enumerations.H:913
This widget simply draws its box, and possibly its label.
Definition Fl_Box.H:34
A button that is used to pop up a menu.
Definition Fl_Choice.H:83
The Fl_Double_Window provides a double-buffered window.
Definition Fl_Double_Window.H:40
The Fl_File_Browser widget displays a list of filenames, optionally with file-specific icons.
Definition Fl_File_Browser.H:39
static const char * preview_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:214
Fl_Widget * add_extra(Fl_Widget *gr)
Adds extra widget at the bottom of Fl_File_Chooser window.
Definition Fl_File_Chooser.cxx:454
static const char * favorites_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:190
void callback(void(*cb)(Fl_File_Chooser *, void *), void *d=0)
Sets the file chooser callback cb and associated data d.
Definition Fl_File_Chooser.cxx:328
static const char * hidden_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:226
int filter_value()
Gets the current filename filter selection.
Definition Fl_File_Chooser.cxx:349
static const char * manage_favorites_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:202
int preview() const
Returns the current state of the preview box.
Definition Fl_File_Chooser.H:149
static const char * new_directory_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:206
static const char * add_favorites_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:174
void color(Fl_Color c)
Sets the background color of the Fl_File_Browser list.
Definition Fl_File_Chooser.cxx:333
static const char * all_files_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:178
static const char * filesystems_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:198
void ok_label(const char *l)
Sets the label for the "ok" button in the Fl_File_Chooser.
Definition Fl_File_Chooser.cxx:381
static const char * filename_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:194
Fl_Check_Button * showHiddenButton
When checked, hidden files (i.e., filename begins with dot) are displayed.
Definition Fl_File_Chooser.H:97
static const char * show_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:222
void iconsize(uchar s)
Sets the size of the icons in the Fl_File_Browser.
Definition Fl_File_Chooser.cxx:365
Fl_File_Chooser(const char *d, const char *p, int t, const char *title)
The constructor creates the Fl_File_Chooser dialog shown.
Definition Fl_File_Chooser.cxx:170
static const char * custom_filter_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:182
void hide()
Hides the Fl_File_Chooser window.
Definition Fl_File_Chooser.cxx:358
void directory(const char *d)
Sets the current directory.
Definition Fl_File_Chooser2.cxx:458
Fl_Check_Button * previewButton
The "preview" button is exported so that application developers can control the appearance and use.
Definition Fl_File_Chooser.H:92
int count()
Returns the number of selected files.
Definition Fl_File_Chooser2.cxx:421
static Fl_File_Sort_F * sort
the sort function that is used when loading the contents of a directory.
Definition Fl_File_Chooser.H:231
Fl_Button * newButton
The "new directory" button is exported so that application developers can control the appearance and ...
Definition Fl_File_Chooser.H:81
void filter(const char *p)
Sets or gets the current filename filter patterns.
Definition Fl_File_Chooser2.cxx:1012
static const char * new_directory_tooltip
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:210
static const char * existing_file_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:186
void preview(int e)
Enable or disable the preview tile.
Definition Fl_File_Chooser2.cxx:1099
static const char * save_label
[standard text may be customized at run-time]
Definition Fl_File_Chooser.H:218
void label(const char *l)
Sets the title bar text for the Fl_File_Chooser.
Definition Fl_File_Chooser.cxx:373
Fl_Preferences provides methods to store user settings between application starts.
Definition Fl_Preferences.H:60
The Fl_Tile class lets you resize its children by dragging the border between them.
Definition Fl_Tile.H:29
unsigned char uchar
unsigned char
Definition fl_types.h:30
#define FL_PATH_MAX
all path buffers should use this length
Definition filename.H:38
int Fl_File_Sort_F(struct dirent **, struct dirent **)
File sorting function.
Definition filename.H:116