The font Command

   

Practical Programming in Tcl & Tk, Third Edition
By Brent B. Welch

Table of Contents
Chapter 39.  Fonts and Text Attributes


The font Command

Table 39-3 summarizes the font command. In the table, font is either a description of font parameters, a logical font name, a system font name, or an X font name. The -displayof option applies to X where you can have windows on different displays that can support different fonts. Note that when you delete a logical font name with font delete, the font is not really deleted if there are widgets that use that font.

Table 39-3. The font command.
font actual font ?-displayof window? ?option?Returns the actual parameters of font.
font configure fontname ?option? ?value option value?Sets or queries the parameters for fontname.
font create ?fontname? ?option value ...?Defines fontname with the specified parameters.
font delete fontname ?name2 ...?Removes the definition for the named fonts.
font families ?-displayof win?Returns the list of font families supported on the display of win.
font measure font ?-displayof win? textReturns the width of text displayed in win with font.
font metrics font ?-displayof win? ?option?The option can be -ascent, -descent, -linespace, or -fixed.
font namesReturns the names of defined fonts.


       
    Top
     



    Practical Programming in Tcl and Tk
    Practical Programming in Tcl and Tk (4th Edition)
    ISBN: 0130385603
    EAN: 2147483647
    Year: 1999
    Pages: 478

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net