smjg.libs.sdwf.commondialog.FontDialog Class Reference

The smjg.libs.sdwf.commondialog.FontDialog class wraps the Windows font common dialog. More...

Inheritance diagram for smjg.libs.sdwf.commondialog.FontDialog:

smjg.libs.sdwf.commondialog.CommonDialog

List of all members.

Public Types

typedef colour color

Public Member Functions

 this (WindowBase p, Font f, RGBColour c)
 Constructs a new FontDialog.
 this (WindowBase p, Font f=null)
 Constructs a new FontDialog.
bool show ()
 Displays the dialog box to select a font.
Properties
Font font ()
 The font selected in the dialog.
Font font (Font f)
 The font selected in the dialog.
float pointSize ()
 The point size of the selected font.
float pointSize (float pt)
 The point size of the selected font.
float pointSize (int pt)
 The point size of the selected font.
float minPointSize ()
 The minimum point size that the user may select.
float minPointSize (float pt)
 The minimum point size that the user may select.
float minPointSize (int pt)
 The minimum point size that the user may select.
float maxPointSize ()
 The maximum point size that the user may select.
float maxPointSize (float pt)
 The maximum point size that the user may select.
float maxPointSize (int pt)
 The maximum point size that the user may select.
string style ()
 A string denoting the font style.
string style (string s)
 A string denoting the font style.

Protected Attributes

LOGFONTA fontSpec


Detailed Description

The smjg.libs.sdwf.commondialog.FontDialog class wraps the Windows font common dialog.

Bug:
Even if the Script drop-down is 'enabled', it remains permanently blank. I have as yet been unable to figure out why.

Member Typedef Documentation

typedef colour smjg.libs.sdwf.commondialog.FontDialog.color


Constructor & Destructor Documentation

smjg.libs.sdwf.commondialog.FontDialog.this ( WindowBase  p,
Font  f,
RGBColour  c 
)

Constructs a new FontDialog.

Parameters:
p the parent window of the dialog.
f the initially selected font.
c the initially selected colour.

smjg.libs.sdwf.commondialog.FontDialog.this ( WindowBase  p,
Font  f = null 
)

Constructs a new FontDialog.

Parameters:
p the parent window of the dialog.
f the initially selected font.


Member Function Documentation

bool smjg.libs.sdwf.commondialog.FontDialog.show (  ) 

Displays the dialog box to select a font.

Return values:
true if the operation succeeded.
false if the operation was cancelled.

Font smjg.libs.sdwf.commondialog.FontDialog.font (  ) 

The font selected in the dialog.

Returns:
a new Font object of the font selected in the dialog. The current implementation does not cache instances.

Font smjg.libs.sdwf.commondialog.FontDialog.font ( Font  f  ) 

The font selected in the dialog.

float smjg.libs.sdwf.commondialog.FontDialog.pointSize (  ) 

The point size of the selected font.

float smjg.libs.sdwf.commondialog.FontDialog.pointSize ( float  pt  ) 

The point size of the selected font.

float smjg.libs.sdwf.commondialog.FontDialog.pointSize ( int  pt  ) 

The point size of the selected font.

float smjg.libs.sdwf.commondialog.FontDialog.minPointSize (  ) 

The minimum point size that the user may select.

float smjg.libs.sdwf.commondialog.FontDialog.minPointSize ( float  pt  ) 

The minimum point size that the user may select.

float smjg.libs.sdwf.commondialog.FontDialog.minPointSize ( int  pt  ) 

The minimum point size that the user may select.

float smjg.libs.sdwf.commondialog.FontDialog.maxPointSize (  ) 

The maximum point size that the user may select.

float smjg.libs.sdwf.commondialog.FontDialog.maxPointSize ( float  pt  ) 

The maximum point size that the user may select.

float smjg.libs.sdwf.commondialog.FontDialog.maxPointSize ( int  pt  ) 

The maximum point size that the user may select.

string smjg.libs.sdwf.commondialog.FontDialog.style (  ) 

A string denoting the font style.

Status:
test

string smjg.libs.sdwf.commondialog.FontDialog.style ( string  s  ) 

A string denoting the font style.

Status:
test


Member Data Documentation

uint smjg.libs.sdwf.commondialog.FontDialog._structSize = CHOOSEFONTA.sizeof

HWND smjg.libs.sdwf.commondialog.FontDialog._parentHandle = null

HDC smjg.libs.sdwf.commondialog.FontDialog.deviceContext = null

The device context of a printer, in order to select printer fonts.

Todo:
connect with the PrintDC class now that SDWF has it

LOGFONTA* smjg.libs.sdwf.commondialog.FontDialog._logFont = null

int smjg.libs.sdwf.commondialog.FontDialog.decipointSize = 0

The font size, in tenths of a point.

This is the internal representation; it is also useful in place of pointSize if the size is desired in decipoints for some purpose.

Todo:
experiment with setting this value (probably no real effect)

CF smjg.libs.sdwf.commondialog.FontDialog.flags

Initial value:

 CF.FORCEFONTEXIST | CF.SCREENFONTS
                                                         | CF.NOSCRIPTSEL
A bitwise combination of flags to customise the font dialog.

RGBColour smjg.libs.sdwf.commondialog.FontDialog.colour

The colour set in the dialog, if the CF.EFFECTS flag has been specified.

int smjg.libs.sdwf.commondialog.FontDialog._customHookData = 0

LPCFHOOKPROC smjg.libs.sdwf.commondialog.FontDialog._hookFunction = null

LPCTSTR smjg.libs.sdwf.commondialog.FontDialog._lpTemplateName = null

HINSTANCE smjg.libs.sdwf.commondialog.FontDialog._instanceHandle = null

LPTSTR smjg.libs.sdwf.commondialog.FontDialog._style = null

FONTTYPE smjg.libs.sdwf.commondialog.FontDialog.fontType = FONTTYPE.NONE

A bitwise combination of flags denoting characteristics of the selected font.

ushort smjg.libs.sdwf.commondialog.FontDialog.___MISSING_ALIGNMENT__

int smjg.libs.sdwf.commondialog.FontDialog.minDecipoints = 0

The minimum font size, in tenths of a point.

This property applies to font dialogs with the CF.LIMITSIZE flag specified.

int smjg.libs.sdwf.commondialog.FontDialog.maxDecipoints = 0

The maximum font size, in tenths of a point.

This property applies to font dialogs with the CF.LIMITSIZE flag specified.

CHOOSEFONTA smjg.libs.sdwf.commondialog.FontDialog.spec

This dialog specification as a Windows CHOOSEFONTA structure.

LOGFONTA smjg.libs.sdwf.commondialog.FontDialog.fontSpec [protected]


The documentation for this class was generated from the following file:
Generated on Sun Jan 11 21:54:11 2009 for Stewart's D Windows Framework by  doxygen 1.5.4