FLTK 1.4.0
fl_ask.cxx File Reference

Utility functions for common dialogs. More...

#include <FL/Fl.H>
#include <FL/Fl_Box.H>
#include <FL/Fl_Input_.H>
#include "flstring.h"
#include "Fl_Screen_Driver.H"
#include <FL/fl_ask.H>
#include "Fl_Message.h"
#include <stdio.h>
#include <stdarg.h>

Functions

void fl_alert (const char *fmt,...)
 Shows an alert message dialog box. More...
 
int fl_ask (const char *fmt,...)
 Shows a dialog displaying the fmt message, this dialog features 2 yes/no buttons. More...
 
void fl_beep (int type)
 Emits a system beep. More...
 
int fl_choice (const char *fmt, const char *b0, const char *b1, const char *b2,...)
 Shows a dialog displaying the printf style fmt message. More...
 
int fl_choice_n (const char *fmt, const char *b0, const char *b1, const char *b2,...)
 Shows a dialog displaying the printf style fmt message. More...
 
const char * fl_input (const char *fmt, const char *defstr,...)
 Shows an input dialog displaying the fmt message with variable arguments. More...
 
const char * fl_input (int maxchar, const char *fmt, const char *defstr,...)
 Shows an input dialog displaying the fmt message with variable arguments. More...
 
void fl_message (const char *fmt,...)
 Shows an information message dialog box. More...
 
int fl_message_hotspot ()
 Gets whether or not to move the message box used in many common dialogs like fl_message(), fl_alert(), fl_ask(), fl_choice(), fl_input(), fl_password() to follow the mouse pointer. More...
 
void fl_message_hotspot (int enable)
 Sets whether or not to move the message box used in many common dialogs like fl_message(), fl_alert(), fl_ask(), fl_choice(), fl_input(), fl_password() to follow the mouse pointer. More...
 
Fl_Widgetfl_message_icon ()
 Gets the Fl_Box icon container of the current default dialog used in many common dialogs like fl_message(), fl_alert(), fl_ask(), fl_choice(), fl_input(), fl_password(). More...
 
void fl_message_icon_label (const char *str)
 Sets the icon label of the dialog window used in many common dialogs. More...
 
void fl_message_position (const int x, const int y, const int center)
 Sets the preferred position for the message box used in many common dialogs like fl_message(), fl_alert(), fl_ask(), fl_choice(), fl_input(), fl_password(). More...
 
void fl_message_position (Fl_Widget *widget)
 Sets the preferred position for the message box used in many common dialogs like fl_message(), fl_alert(), fl_ask(), fl_choice(), fl_input(), fl_password(). More...
 
int fl_message_position (int *x, int *y)
 Gets the preferred position for the message box used in many common dialogs like fl_message(), fl_alert(), fl_ask(), fl_choice(), fl_input(), fl_password(). More...
 
void fl_message_title (const char *title)
 Sets the title of the dialog window used in many common dialogs. More...
 
void fl_message_title_default (const char *title)
 Sets the default title of the dialog window used in many common dialogs. More...
 
const char * fl_password (const char *fmt, const char *defstr,...)
 Shows an input dialog displaying the fmt message with variable arguments. More...
 
const char * fl_password (int maxchar, const char *fmt, const char *defstr,...)
 Shows an input dialog displaying the fmt message with variable arguments. More...
 

Variables

const char * fl_cancel = "Cancel"
 string pointer used in common dialogs, you can change it to another language
 
const char * fl_close = "Close"
 string pointer used in common dialogs, you can change it to another language
 
Fl_Font fl_message_font_ = FL_HELVETICA
 
Fl_Fontsize fl_message_size_ = -1
 
const char * fl_no = "No"
 string pointer used in common dialogs, you can change it to another language
 
const char * fl_ok = "OK"
 string pointer used in common dialogs, you can change it to another language
 
const char * fl_yes = "Yes"
 string pointer used in common dialogs, you can change it to another language
 

Detailed Description

Utility functions for common dialogs.

This file defines the functions

and some more functions to change their behavior (positioning, window title, and more).

Since FLTK 1.4.0 a big part of these functions is implemented in class Fl_Message.