Compare commits
3 Commits
tk-8.5.19.
...
tk-8.6.8.0
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
753ac6b037 | ||
|
|
8e57feeeb9 | ||
|
|
b1c28856bb |
5283
ChangeLog.2007
Normal file
5283
ChangeLog.2007
Normal file
File diff suppressed because it is too large
Load Diff
10
README
10
README
@@ -1,18 +1,18 @@
|
||||
README: Tk
|
||||
This is the Tk 8.5.19 source distribution.
|
||||
This is the Tk 8.6.8 source distribution.
|
||||
http://sourceforge.net/projects/tcl/files/Tcl/
|
||||
You can get any source release of Tk from the URL above.
|
||||
|
||||
1. Introduction
|
||||
---------------
|
||||
|
||||
This directory contains the sources and documentation for Tk, a
|
||||
cross-platform GUI toolkit implemented with the Tcl scripting language.
|
||||
This directory contains the sources and documentation for Tk, an X11
|
||||
toolkit implemented with the Tcl scripting language.
|
||||
|
||||
For details on features, incompatibilities, and potential problems with
|
||||
this release, see the Tcl/Tk 8.5 Web page at
|
||||
this release, see the Tcl/Tk 8.6 Web page at
|
||||
|
||||
http://www.tcl.tk/software/tcltk/8.5.html
|
||||
http://www.tcl.tk/software/tcltk/8.6.html
|
||||
|
||||
or refer to the "changes" file in this directory, which contains a
|
||||
historical record of all changes to Tk.
|
||||
|
||||
2
README.md
Normal file
2
README.md
Normal file
@@ -0,0 +1,2 @@
|
||||
# cpython-source-deps
|
||||
Source for packages that the cpython build process depends on
|
||||
589
changes
589
changes
@@ -6500,12 +6500,23 @@ Several documentation and release notes improvements
|
||||
|
||||
--- Released 8.5.2, March 28, 2008 --- See ChangeLog for details ---
|
||||
|
||||
2008-04-01 (interface)[1819422] tkStubsPtr no longer in libtk (porter)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2008-04-02 (interface)[1819422] libtkstub symbols MODULE_SCOPE (steffen)
|
||||
|
||||
2008-04-07 (bug fix)[1937135] Tk_ParseArgv() double free crash (hobbs)
|
||||
|
||||
2008-04-07 (bug fix)[1936238] wish -h mem explosion (bachmann,kenny)
|
||||
|
||||
2008-04-08 (new feature) Win: visual-styles API element engine (thoyts)
|
||||
|
||||
2008-04-09 (enhancement) real LZW compression in GIF writer (nijtmans)
|
||||
|
||||
2008-04-14 (bug fix)[1941740] [tk_chooseColor -title] (thoyts)
|
||||
|
||||
2008-04-16 (interface)[1938497] make stubs tables 'static const' (steffen)
|
||||
|
||||
2008-04-17 (bug fix)[1327482] canvas item <Enter> events (wangnick)
|
||||
|
||||
2008-05-23 (bug fix)[1967576] ttk::label height or width 0 panic (lawlor)
|
||||
@@ -6516,12 +6527,17 @@ Several documentation and release notes improvements
|
||||
|
||||
2008-06-12 (platform support) Solaris/amd64 gcc 64bit support (steffen)
|
||||
|
||||
2008-06-13 (new feature)[TIP 285] [tkwait] and [update] are now
|
||||
[interp cancel]able (mistachkin)
|
||||
|
||||
2008-06-18 (bug fix) Aqua: missing focus on first map (steffen)
|
||||
|
||||
--- Released 8.5.3, June 30, 2008 --- See ChangeLog for details ---
|
||||
--- Released 8.6a1, June 25, 2008 --- See ChangeLog for details ---
|
||||
|
||||
2008-07-04 (bug fix)[2009213] crash in [ttk::scale] (polo,english)
|
||||
|
||||
2008-07-24 (bug fix)[2021443] consistent "wrong # args" messages (nijtmans)
|
||||
|
||||
2008-07-26 (bug fix)[2026405] portability of [winfo id] (uchida,thoyts)
|
||||
|
||||
2008-07-31 (bug fix) export Tk_PkgInitStubsCheck; fixes Tk embed on Windows
|
||||
@@ -6531,12 +6547,15 @@ Several documentation and release notes improvements
|
||||
2008-08-05 (bug fix)[2010422] Tk header files revised to accommodate
|
||||
incompatible changes in recent X.org releases of X11 headers. (jenglish)
|
||||
|
||||
--- Released 8.5.4, August 15, 2008 --- See ChangeLog for details ---
|
||||
2008-08-19 (bug fix) revised number format in -[xy]scrollcommand callbacks
|
||||
and [xy]view methods (jenglish)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2008-08-19 (behavior change) arguments passed to -[xy]scrollcommand
|
||||
callbacks, and values returned by [xy]view methods are explicitly
|
||||
formatted as doubles. (english)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
2008-08-19 (enhancement) removed obsolete XID management code (staplin)
|
||||
|
||||
Test suite modernization by Ania Pawelczyk.
|
||||
|
||||
--- Released 8.6a2, August 25, 2008 --- See ChangeLog for details ---
|
||||
|
||||
2008-08-25 (bug fix)[1936220] fix [tk_getOpenFile -multiple 1] on unix (helfter)
|
||||
|
||||
@@ -6544,48 +6563,100 @@ formatted as doubles. (english)
|
||||
|
||||
2008-08-28 (bug fix) correct TK_LIBS value to include Xft (porter)
|
||||
|
||||
2008-09-03 (support) Dropped support for pre-ANSI compilers. (porter)
|
||||
|
||||
2008-10-01 (new feature)[TIP 236] [$canvas moveto] (mckay,fellows)
|
||||
|
||||
2008-10-05 (bug fix)[2112563] format double values explicitly in double
|
||||
format, avoiding sensitivity to locale setting. (fellows)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2008-10-10 (bug fix)[1894038] [package require] any Tk 8.5.* in any Tcl 8.5.*
|
||||
(porter)
|
||||
|
||||
--- Released 8.5.5, October 15, 2008 --- See ChangeLog for details ---
|
||||
--- Released 8.6a3, October 10, 2008 --- See ChangeLog for details ---
|
||||
|
||||
2008-10-17 (enhancement) keyboard bindings for ttk::scale (thoyts)
|
||||
|
||||
2008-10-18 (bug fix)[1825353] Russian Windows tiny fonts problem (thoyts)
|
||||
|
||||
2008-10-18 (new feature)[TIP 321] [tk busy] (decoster,fellows)
|
||||
|
||||
2008-10-28 (bug fix)[1534835,2054562] use of more correct cursors (english)
|
||||
|
||||
2008-11-01 (new feature) New [ttk::spinbox] widget (thoyts)
|
||||
|
||||
2008-11-01 (new feature)[TIP 97] [$canvas imove] [$canvas rchars] (fellows)
|
||||
|
||||
2008-11-09 (bug fix)[2207435] [ttk::entry .t -textvar ::noexist::x] (english)
|
||||
|
||||
2008-11-11 (bug fix)[2312027] Tk_Create*ImageType() thread safety (nijtmans)
|
||||
|
||||
2008-11-11 (bug fix)[2264732] crash using nondefault visual (english)
|
||||
|
||||
2008-11-12 (bug fix)[1777362] permit [text] names containing "-" (thoyts)
|
||||
|
||||
2008-11-15 (bug fix)[2239034] limit [wm manage] to Frames (thoyts)
|
||||
2008-11-14 (bug fix)[2239034] limit [wm manage] to Frames (thoyts)
|
||||
|
||||
2008-11-19 (bug fix)[2312027] Tk_Create*ImageType() thread safety (nijtmans)
|
||||
2008-11-22 (new feature)[TIP 119] -angle option for canvas text items (fellows)
|
||||
|
||||
2008-11-22 (bug fix)[1939129,1991930] combobox behind other windows (thoyts)
|
||||
|
||||
2008-12-22 (bug fix)[1813597,2218964] eliminate unnecessary units conversion
|
||||
2008-11-22 (new feature) Demo ctext.tcl now demos angled text (fellows)
|
||||
|
||||
2008-11-23 (bug fix)[1389270] made [event generate <Focus*>] work (thoyts)
|
||||
|
||||
2008-11-28 (bug fix)[1813597,2218964] eliminate unnecessary units conversion
|
||||
in screen distances, reducing precision loss (ferrieux)
|
||||
|
||||
2008-12-22 (bug fix)[2107938] no negative font size in PS (fellows)
|
||||
2008-12-03 (enhancement) new "hover" state for proper Vista visuals (thoyts)
|
||||
|
||||
2008-12-22 (bug fix)[2264732] crash using nondefault visual (english)
|
||||
2008-12-05 (bug fix)[2107938] no negative font size in PS (fellows)
|
||||
|
||||
2008-12-22 (bug fix)[2207435] [ttk::entry .t -textvar ::noexist::x] (english)
|
||||
2008-12-05 (enhancement) new "vista" theme (thoyts)
|
||||
|
||||
--- Released 8.5.6, December 23, 2008 --- See ChangeLog for details ---
|
||||
2008-12-06 (new feature)[TIP 197] [$text -insertunfocussed] (edwards,fellows)
|
||||
|
||||
2008-12-06 (new feature)[TIP 337] handle non-error bg exceptions (porter)
|
||||
|
||||
2008-12-10 (new feature)[TIP 324] [tk fontchooser](thoyts,vetter,robert,steffen)
|
||||
|
||||
2008-12-12 (new feature) Demo fontchoose.tcl demos [tk fontchooser] (thoyts)
|
||||
|
||||
2008-12-18 (enhancement)[24442309] Updated German messages (haertel)
|
||||
|
||||
--- Released 8.6b1, December 19, 2008 --- See ChangeLog for details ---
|
||||
|
||||
2008-12-27 (bug fix)[2381555] horiz. scroll [$treeview identify] (english)
|
||||
|
||||
2008-12-28 (new feature)[TIP 244] PNG photo format support (fellows)
|
||||
|
||||
2008-12-28 (new feature)[TIP 171] <MouseWheel> event handling (fellows)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2008-12-31 (bug fix)[2003310] radio|check button indicator color (english)
|
||||
|
||||
2009-01-06 (bug fix)[2484771] messagebox: system to task modal (ferrieux,thoyts,mjanssen)
|
||||
|
||||
2009-01-06 (enhancement)[1539990] optimize photo building (jepler)
|
||||
|
||||
2009-01-07 (bug fix)[2473120] chooseDir syntax error (bron)
|
||||
|
||||
2009-01-07 (bug fix)[1847002] Win: prevent grab bypass (thoyts)
|
||||
|
||||
2009-01-11 (bug fix)[2496162] crash calling Tk_DeleteOptionTable() (english)
|
||||
|
||||
2009-01-11 (bug fix) crash on XCreateIC failure (staplin)
|
||||
|
||||
2009-01-14 (bug fix)[2507326] Restore aMSN compat (nijtmans)
|
||||
|
||||
2009-01-19 (new feature) CONFIG_INSTALL_DIR - where tclConfig.sh goes (cassoff)
|
||||
2009-01-19 (new feature) CONFIG_INSTALL_DIR - where tkConfig.sh goes (cassoff)
|
||||
|
||||
2009-01-19 (platform support) better tools for BSD ports (cassoff)
|
||||
|
||||
2009-02-08 (bug fix)[2431428] panic computing layout on active widget (english)
|
||||
|
||||
2009-02-17 (platform support) MSVC and _WIN64 (hobbs)
|
||||
|
||||
2009-02-21 (bug fix)[2546087] [console] display of true UTF-8 \0 (thoyts)
|
||||
|
||||
2009-02-23 (bug fix)[1329198,456299,2507419] menu image display (mcdonald)
|
||||
|
||||
2009-02-23 (bug fix)[2513104] fix cursor hotspots (mcdonald)
|
||||
@@ -6594,13 +6665,23 @@ in screen distances, reducing precision loss (ferrieux)
|
||||
|
||||
2009-02-27 (bug fix)[2645457] crash in Tk_MakeWindowExist() (thoyts)
|
||||
|
||||
2009-03-09 (bug fix)[2548661] crash in GetFontFamilyName (riefenstahl)
|
||||
|
||||
2009-03-25 (bug fix)[2178820] stop zero-size allocs in ttk (fellows)
|
||||
|
||||
2009-03-25 (bug fix)[1871101] blurry large fonts on Vista (garvey,fellows)
|
||||
|
||||
2009-04-03 (bug fix)[1789819] stop panic on unexpected wm stack order (english)
|
||||
|
||||
2009-04-10 (bug fix)[2116837] std virtual events with Caps Lock (fellows)
|
||||
|
||||
--- Released 8.5.7, April 15, 2009 --- See ChangeLog for details ---
|
||||
2009-04-10 (platform) sse Darwin SUSv3 extensions if available (steffen)
|
||||
|
||||
2009-04-10 (bug fix) Motif checkbutton on X11 only (steffen)
|
||||
|
||||
2009-04-10 (bug fix) remove TkAqua Quit menu item on [console] (steffen)
|
||||
|
||||
2009-04-10 (bug fix) crash deleting char range from [text] (steffen)
|
||||
|
||||
2009-04-23 (bug fix)[2779910] updated Win chooseDir (hobbs)
|
||||
|
||||
@@ -6610,6 +6691,8 @@ in screen distances, reducing precision loss (ferrieux)
|
||||
|
||||
2009-04-30 (bug fix)[2504402] iconphoto on non-32-bit displays (mcdonald,thoyts)
|
||||
|
||||
2009-05-01 (bug fix)[2777019] anchor for text rotation (gavilán,fellows)
|
||||
|
||||
2009-05-03 (bug fix)[2785744] broken flag twiddling (baker,fellows)
|
||||
|
||||
2009-05-13 (bug fix)[2791352] XLFD parsing error (thoyts)
|
||||
@@ -6618,20 +6701,42 @@ in screen distances, reducing precision loss (ferrieux)
|
||||
|
||||
2009-05-14 (bug fix)[1923684] confused checkbutton state (thoyts)
|
||||
|
||||
2009-05-17 (new feature)[1470246] notebook tab orientation control (english)
|
||||
|
||||
2009-05-21 (bug fix)[2794778] Win menu keyboard traversal (thoyts)
|
||||
|
||||
2009-06-02 (bug fix)[2799589] crash on delayed window activation (thoyts)
|
||||
|
||||
2009-06-23 (bug fix)[220935] canvas dash update problem (nijtmans)
|
||||
|
||||
2009-06-23 (platform) new subdir 'carbon' preserved for OSX 10.4-
|
||||
use --enable-aqua=carbon option to unix/configure to enable (steffen)
|
||||
|
||||
2009-06-29 (new feature) source in `macosx` now built on Cocoa (steffen)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2009-06-30 (platform support) clang static analyzer macros (steffen)
|
||||
|
||||
2009-07-15 (bug fix)[2821962] photo image copy/paste (rib,fellows)
|
||||
|
||||
2009-07-21 (bug fix)[2356057] rotated underlined text (fellows)
|
||||
|
||||
2009-07-22 (bug fix)[2496114] focus in dead window crash (griffin,fellows)
|
||||
|
||||
2009-07-23 (bug fix)[2441988] report errors in selection handlers (fellows)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2009-08-01 (bug fix)[2830420] X iconphoto for big endian (misch,fellows)
|
||||
|
||||
2009-08-04 (bug fix) [text] word-wrap of non-breaking space (fellows)
|
||||
|
||||
2009-08-14 (bug fix) copy from unmapped toplevel crash (alaoui,steffen)
|
||||
|
||||
2009-08-19 (bug fix)[2475855] prevent grid & pack on same master (spjuth)
|
||||
|
||||
2009-08-24 (bug fix)[2821084] Cocoa: let WM_DELETE_WINDOW handler stop window
|
||||
deletion (walzer,steffen)
|
||||
|
||||
2009-08-24 (bug fix) tk::MessageBox bindings for ttk::buttons (steiner,fellows)
|
||||
|
||||
2009-08-25 (bug fix)[1909931] [send] update for Fedora 8 (fellows)
|
||||
@@ -6652,13 +6757,13 @@ in screen distances, reducing precision loss (ferrieux)
|
||||
|
||||
2009-10-10 (feature)[1961455] underline, overstrike Xft fonts (caffin,fellows)
|
||||
|
||||
2009-10-15 (feature)[2794032] permit [load] into Tcl 8.6+ interps (porter)
|
||||
2009-10-20 (enhancement) Updates to Polish messages (pawlak)
|
||||
|
||||
2009-10-22 (bug fix)[2168768] file dialog -typevariable scope (danckaert)
|
||||
|
||||
2009-10-22 (bug fix)[1469210] [text] modified error (danckaert)
|
||||
|
||||
2009-10-24 (bug fix)[2883712] 64-bit Aqua progress bar (haffner)
|
||||
2009-10-22 (bug fix)[2883712] 64-bit Aqua progress bar (haffner)
|
||||
|
||||
2009-10-24 (bug fix)[1530276] X checkbutton -selectcolor (danckaert)
|
||||
|
||||
@@ -6668,36 +6773,39 @@ in screen distances, reducing precision loss (ferrieux)
|
||||
|
||||
2009-10-29 (bug fix)[1825353] Russian Windows tiny fonts problem (thoyts)
|
||||
|
||||
2009-11-03 (bug fix)[2891541] fix grab behaviour for main window (thoyts)
|
||||
2009-11-01 (new feature) Ttk: [$w identify] now an ensemble (jenglish)
|
||||
|
||||
--- Released 8.5.8, November 16, 2009 --- See ChangeLog for details ---
|
||||
2009-11-19 (bug fix)[2899685] fix [imove] redraw logic (schekin,ferrieux)
|
||||
|
||||
2009-11-22 (bug fix)[2899949] crash on widget destroy (meier,thoyts)
|
||||
|
||||
2009-11-23 (bug fix)[2902573] Update Safe Tk to new Safe Base (kurpies)
|
||||
|
||||
2009-11-24 (bug fix)[2902814] fix [wm iconphoto] on LP64 systems (fellows)
|
||||
|
||||
2009-12-06 (bug fix)[2548661] crash in GetFontFamilyName (riefenstahl)
|
||||
|
||||
2009-12-06 (bug fix)[2864685] Compiz menu item animation (gavilán,thoyts)
|
||||
|
||||
2009-12-09 (bug fix)[2902573] Update Safe Tk to new Safe Base (kurpies)
|
||||
2009-12-08 (bug fix)[2864685] Compiz menu item animation (gavilán,thoyts)
|
||||
|
||||
2009-12-11 (bug fix)[2912473] accept :: in DISPLAY name (fellows)
|
||||
|
||||
2009-12-16 (bug fix)[2496162] crash calling Tk_DeleteOptionTable() (english)
|
||||
2009-12-15 (bug fix)[2492179] Tcl_ObjType "option" no longer registered (porter)
|
||||
*** POTENTIAL INCOMPATIBILITY for Tcl_GetObjType("option") ***
|
||||
|
||||
2009-12-20 (bug fix)[2917663] [send] accept SI:* on auth list (fellows)
|
||||
|
||||
2009-12-22 (bug fix)[2919205] syntax bug in [tk_messageBox] (zaroo)
|
||||
|
||||
2009-12-22 (bug fix)[2912356] [ttk::sizegrip] accommodate Compiz (english)
|
||||
|
||||
2009-12-25 (bug fix)[2977688,2546779] tab selection focus (english)
|
||||
|
||||
2009-12-27 (bug fix)[2879927] Win: cascade menu highlight (pawlak,thoyts)
|
||||
|
||||
2010-01-01 (bug fix)[1924761] stop [event generate] / XIM conflict (fellows)
|
||||
|
||||
2010-01-03 (bug fix)[2848897] ODS_NOACCEL flag support (kovalenko,thoyts)
|
||||
|
||||
2010-01-04 (bug fix)[2811266] <Return> binding in [tk_dialog] (thoyts)
|
||||
|
||||
2010-01-04 (bug fix)[2727476] font dialog appearance (thoyts)
|
||||
|
||||
2010-01-05 (bug fix)[220950] [$menu delete] bounds check (fellows)
|
||||
|
||||
2010-01-05 [2898255] unlimited multi-file select (pawlak,fellows,thoyts)
|
||||
@@ -6708,44 +6816,93 @@ in screen distances, reducing precision loss (ferrieux)
|
||||
|
||||
2010-01-18 (bug fix)[2932808] canvas update on state change (mcdonald,nijtmans)
|
||||
|
||||
2010-01-19 (bug fix)[2931374] overflow in complex tag search (schmitz)
|
||||
|
||||
2010-01-19 (new feature)[TIP 359] Extended Window Manager Hint Support (thoyts)
|
||||
|
||||
2010-01-19 (bug fix)[2931374] overflow in complex tag search (schmitz)
|
||||
|
||||
2010-02-17 (bug fix)[2952745] crash in menu deletion (english)
|
||||
|
||||
2010-02-20 (performance) treeview stop quadratic common case (english)
|
||||
|
||||
2010-03-02 (enhancement) -fvisibility-hidden build support (nijtmans)
|
||||
|
||||
2010-03-06 (bug fix)[2949774] cascade menu unpost (thoyts)
|
||||
|
||||
2010-03-11 (bug fix)[2968379] crash in peer text dump (fellows)
|
||||
|
||||
2010-03-17 (bug fix)[2971663] Cocoa entry <Up>, <Down> (goddard,fellows)
|
||||
|
||||
2010-03-28 (new feature) [$treeview tag names|add|remove] (english)
|
||||
|
||||
2010-04-09 (new feature)[2983824] [$image write -file] use extension of file
|
||||
name to select image format (fellows)
|
||||
|
||||
2010-04-19 [2898255] unlimited multi-file select (pawlak,fellows,thoyts)
|
||||
|
||||
2010-05-31 (bug fix)[3006842] crash on empty bind scripts (english)
|
||||
|
||||
2010-06-15 (bug fix)[2585265] text <Delete>,<Backspace> note selection (fellows)
|
||||
|
||||
2010-06-15 (new package)[3016598] Tk now provides "tile 0.8.6" (english)
|
||||
|
||||
2010-07-19 (new feature) [$photo data -format GIF] (fellows)
|
||||
|
||||
2010-08-03 (bug fix) entry validation compat with Itcl scope (hobbs)
|
||||
|
||||
2010-08-12 (bug fix)[2585265] text <Delete>,<Backspace> note selection (fellows)
|
||||
2010-08-11 (platform) Drop pre-aix 4.2 support, ldAix (hobbs)
|
||||
|
||||
2010-08-25 (feature)[3053320] update Ttk to tile 0.8.6 feature set (hobbs)
|
||||
2010-08-21 (patch)[3034251] genStubs steal features of ttkGenStubs (nijtmans)
|
||||
|
||||
--- Released 8.5.9, September 6, 2010 --- See ChangeLog for details ---
|
||||
2010-08-26 (bug fix)[1230554] configure, OSF-1 problems, windows manifest issues (hobbs)
|
||||
|
||||
2010-08-31 fixed manifest handling on windows (hobbs, kupries)
|
||||
|
||||
2010-09-02 (bug fix)[3057573] specify combobox text fg color (english)
|
||||
|
||||
2010-09-05 (enhancement)[3046742,3046750] Improved error dialog UI (fellows)
|
||||
|
||||
2010-09-08 (bug fix)[2829363] [$tv see] open item -> sched display (english)
|
||||
|
||||
2010-09-13 (platform) limit support to Win2000+ (nijtmans)
|
||||
|
||||
2010-10-01 (bug fix)[3078902] no hang operating on zero-size subimages (fellows)
|
||||
|
||||
2010-10-05 (bug fix)[3080953] corrupt multibyte char in %A subst (nijtmans)
|
||||
|
||||
2010-10-11 (bug fix)[3085489] crash in [tag add/remove] (english)
|
||||
|
||||
2010-11-04 (enhancement) Updated German messages. (haertel,nijtmans)
|
||||
2010-10-11 (enhancement)[491789] Unicode command line support on Win (nijtmans)
|
||||
|
||||
2010-11-03 windows build with -UNICODE (nijtmans)
|
||||
|
||||
2010-11-05 Message catalogs reworked to use unicode copyright char (nijtmans)
|
||||
|
||||
2010-11-06 Message catalogs resorted, updates to NL (nijtmans)
|
||||
|
||||
2010-11-16 (platform) VS 2005 SP1 MSVC compiler (nijtmans)
|
||||
|
||||
2010-11-24 (bug fix)[3071836] crash in tk_getSaveFile (twylite)
|
||||
|
||||
2010-12-03 (enhancement)[3116490] mingw x-compile improvements (nijtmans)
|
||||
|
||||
2010-12-12 (platform) OpenBSD build improvements (cassoff)
|
||||
|
||||
2010-12-17 (platform) Revisions to support rpm 4.4.2 (cassoff)
|
||||
|
||||
2011-01-06 (bug fix)[2857300] Cocoa: correct text width rounding (walzer)
|
||||
|
||||
2011-01-06 (bug fix)[3086887] Cocoa: textured bg windows (walzer)
|
||||
|
||||
2011-01-13 (bug fix)[3154705] tk_messageBox close button disabled (skylera)
|
||||
|
||||
2011-01-22 (enhancement) add [ttk::entry validate] (schelte,english)
|
||||
|
||||
2011-01-24 (bug fix)[2907388] OSX: composite character entry crash (berg,walzer)
|
||||
|
||||
2011-03-02 (new doc) tk_mac.n: OS X specific functions (walzer)
|
||||
|
||||
2011-03-03 (bug fix)[3175610] incomplete line item refresh (ferrieux)
|
||||
|
||||
2011-03-10 (bug fix)[3205260] crash in [wm manage] (boudaillier, thoyts)
|
||||
|
||||
2011-03-16 (bug fix)[3181181] tearoff submenu fix (menez, thoyts)
|
||||
@@ -6767,24 +6924,20 @@ in screen distances, reducing precision loss (ferrieux)
|
||||
2011-04-22 (bug fix)[3291543] mem corrupt when [$canvas dchars] removes all
|
||||
coords of a polygon (rogers,spjuth)
|
||||
|
||||
2011-04-30 (bug fix)[2949774] cascade menu unpost (thoyts)
|
||||
2011-04-29 (platform support) [wm forget|manage] on OS X (walzer)
|
||||
|
||||
2011-06-06 (bug fix)[2546087] [console] treatment of '\0' (porter)
|
||||
|
||||
2011-06-07 (bug fix)[2358545] Restore "08" in spinbox configured with -from
|
||||
and -to (porter)
|
||||
|
||||
2011-06-07 (bug fix)[2484771] modal dialog settings (hoff, thoyts)
|
||||
|
||||
2011-06-10 (bug fix)[3175610] incomplete line item refresh (ferrieux)
|
||||
2011-06-10 (bug fix)[3315731] fix [$entry -invcmd] (porter)
|
||||
|
||||
2011-06-17 (bug fix)[3062331] crash in unset traces (macdonald,porter)
|
||||
|
||||
--- Released 8.5.10, June 23, 2011 --- See ChangeLog for details ---
|
||||
2011-08-03 (bug fix)[2891541] fix grab behaviour for main window (thoyts)
|
||||
|
||||
2011-06-29 (bug fix)[3341056] new crash in unset traces (militaru,porter)
|
||||
|
||||
2011-08-03 (bug fix)[3314770] restore file dialog resizeability (nijtmans)
|
||||
--- Released 8.6b2, August 8, 2011 --- See ChangeLog for details ---
|
||||
|
||||
2011-09-22 (bug fix)[3404541] -takefocus option (dzach,english)
|
||||
|
||||
@@ -6792,10 +6945,6 @@ and -to (porter)
|
||||
|
||||
2011-10-25 (bug fix)[3410609] AltGr keysyms on Swiss keyboard (tasser,kenny)
|
||||
|
||||
2011-11-02 (performance)[3431491] improved "pixels" shimmer logic (fellows)
|
||||
|
||||
--- Released 8.5.11, November 4, 2011 --- See ChangeLog for details ---
|
||||
|
||||
2011-11-17 (bug fix)[3437816] return code of [canvas lower] (hirner,ferrieux)
|
||||
|
||||
2011-12-22 (bug fix)[3235256] correct menu failure on Windows (mcdonald)
|
||||
@@ -6842,35 +6991,54 @@ and -to (porter)
|
||||
|
||||
2012-07-23 (bug fix)[3546073] DisplayString() -> DefaultDisplay() (english)
|
||||
|
||||
Many revisions to better support a Cygwin environment (nijtmans)
|
||||
|
||||
--- Released 8.5.12, July 27, 2012 --- See ChangeLog for details ---
|
||||
|
||||
2012-07-31 (update)[3551802] XKeycodeToKeysym deprecation (fellows)
|
||||
|
||||
2012-08-11 (bug fix)[3554273] text elide and tags (vogel)
|
||||
|
||||
2012-08-15 (enhancement)[3555324] Win:Ctrl-A now means Select-All (nijtmans)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2012-08-22 (new feature)[TIP 403] Use Web color definitions (nijtmans)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2012-08-23 (enhancement)[3555644] better use of virtual events (nijtmans)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2012-08-24 (bug fix)[3558535] file dialog filtering (fellows)
|
||||
|
||||
2012-08-25 (bug fix)[3554026,3561016] crash with tearoff menus (gavilán)
|
||||
|
||||
2012-08-28 (bug fix)[3562426] Context menu goes off screen (nijtmans)
|
||||
|
||||
2012-09-11 (bug fix)[3566594] stop clip region leaks (fellows)
|
||||
|
||||
2012-09-28 New colors: aqua crimson fuchsia indigo lime olive silver teal
|
||||
2012-09-15 (bug fix)[3567778] stop hang in wrapped label (porter)
|
||||
|
||||
2012-09-17 (bug fix)[3567786] stop segfault in [wm forget] (porter)
|
||||
|
||||
Many revisions to better support a Cygwin environment (nijtmans)
|
||||
|
||||
--- Released 8.6b3, September 18, 2012 --- See ChangeLog for details ---
|
||||
|
||||
2012-10-02 (bug fix)[3572016] menu enable after modal dialog (berg,walzer)
|
||||
|
||||
2012-10-08 Remove Carbon support
|
||||
|
||||
2012-10-24 (bug fix)[3574893] crash in [wm forget] (porter)
|
||||
|
||||
2012-11-07 (bug fix)[3574708] TkSetFocusWin() crash on XP (mcdonald)
|
||||
2012-11-07 (bug fix)[3574708] crash in focus handling (fellows)
|
||||
|
||||
--- Released 8.5.13, November 12, 2012 --- See ChangeLog for details ---
|
||||
2012-11-14 (bug fix)[3500545] fix [tk_getOpenFile -multiple] (bruederlin)
|
||||
|
||||
2012-12-04 (bug fix)[3588824] text index of images with weird names (gavilan)
|
||||
2012-12-04 (bug fix)[3588824] Support weird image names in [text] (vogel)
|
||||
|
||||
2012-12-06 (bug fix) avoid buggy syscall to parse hex color values (fellows)
|
||||
2012-12-06 (bug fix)[3592736] stop pink greys from buggy mingw builds (fellows)
|
||||
|
||||
--- Released 8.6.0, December 20, 2012 --- See ChangeLog for details ---
|
||||
|
||||
2013-01-04 (bug fix) Tk_InitStubs("8.6") rejected in 8.60 interp (nijtmans)
|
||||
|
||||
2013-01-10 (bug fix)[3600251] Mac <Control-v> binding (kjnash,nijtmans)
|
||||
|
||||
2013-01-10 (bug fix)[3600260] <<SelectNextPara>> binding (kjnash,nijtmans)
|
||||
|
||||
2013-01-13 (bug fix)[3600290] restore $tk_strictMotif respect (kjnash,nijtmans)
|
||||
|
||||
2013-01-22 (bug fix)[3601782] Tcl_InitStubs failure message (nijtmans)
|
||||
|
||||
@@ -6888,29 +7056,23 @@ Many revisions to better support a Cygwin environment (nijtmans)
|
||||
|
||||
2013-04-01 (bug fix)[3607830] Xkb runtime checks (griffin)
|
||||
|
||||
--- Released 8.5.14, April 3, 2013 --- See ChangeLog for details ---
|
||||
|
||||
2013-05-19 (platform support) FreeBSD updates (cerutti)
|
||||
|
||||
2013-06-05 (bug fix)[3613759] [ttk::entry .e; .e xview end] (nijtmans)
|
||||
|
||||
2013-06-05 (bug fix)[2100430] [ttk::entry .e; .e xview insert] (nijtmans)
|
||||
|
||||
2013-06-07 (bug fix)[1913750,3500545,3416492,3095112] file dialogs (nijtmans)
|
||||
|
||||
2013-06-28 (bug fix)[2501278] reverse ttk::scale key bindings {mcdonald)
|
||||
|
||||
2013-06-28 (bug fix)[3588364] crash loading Tk 64-bit windows (nijtmans)
|
||||
|
||||
2013-07-02 (bug fix)[32afa6] corrected dirent64 check (griffin)
|
||||
|
||||
2013-08-14 (bug fix)[069c9e] "option" value refcount crash (tim,nijtmans)
|
||||
|
||||
2013-08-15 (bug fix)[c597acd] [$pb step] work with traces (english)
|
||||
|
||||
2013-08-25 (bug fix)[3016181] Cocoa: [destroy $scrollbar] => crash (goddard)
|
||||
|
||||
2013-08-26 (bug fix)[c597acd] [$pb step] work with traces (english)
|
||||
|
||||
2013-09-15 (bug fix)[8eb5671] macosx Tk compile errors w/clang (deily)
|
||||
|
||||
--- Released 8.5.15, September 18, 2013 --- http://core.tcl.tk/tk/ for details
|
||||
--- Released 8.6.1, September 19, 2013 --- http://core.tcl.tk/tk/ for details
|
||||
|
||||
2013-10-27 (bug fix) OSX drawing lags (deily,steffen,walzer)
|
||||
|
||||
@@ -6918,12 +7080,16 @@ Many revisions to better support a Cygwin environment (nijtmans)
|
||||
|
||||
2013-10-31 (bug fix) C++ friendly stubs struct declarations (nijtmans)
|
||||
|
||||
2013-10-31 (bug fix)[c0cc9fd] PNG parser accept uppercase -format (nijtmans)
|
||||
|
||||
2013-10-31 (bug fix) double free of a TkFont (nijtmans)
|
||||
|
||||
2013-11-03 (bug fix)[1632447] support PPM maxval up to 65535 (fellows)
|
||||
|
||||
2013-11-05 (bug fix)[426679e] OpenBSD man page rendering (nijtmans)
|
||||
|
||||
2013-11-11 (bug fix)[f214b8a] multi-interp font teardown double free (porter)
|
||||
|
||||
2013-11-11 (bug fix)[0aa5e85] option file \n syntax support (nijtmans)
|
||||
|
||||
2013-11-20 (platforms) Support for Windows 8.1 (nijtmans)
|
||||
@@ -6934,6 +7100,8 @@ Many revisions to better support a Cygwin environment (nijtmans)
|
||||
|
||||
2014-02-06 (bug fix)[3279221] [menu] event race (danckaert,kupries)
|
||||
|
||||
2014-02-07 (bug fix)[6867cc1] creative writing in [tk fontchooser] (nijtmans)
|
||||
|
||||
2014-02-11 (bug fix)[52ca3e7] XkbOpenDisplay macro correction (nijtmans)
|
||||
|
||||
2014-03-16 (bug fix) Xcode 5.1 update; Retina displays (walzer)
|
||||
@@ -6946,11 +7114,13 @@ Many revisions to better support a Cygwin environment (nijtmans)
|
||||
|
||||
2014-07-07 (bug fix) OSX alpha channel rendering (culler,walzer)
|
||||
|
||||
2014-07-08 (workaround)[4955f5d] Ocaml trouble with tailcall splice (nijtmans)
|
||||
|
||||
2014-07-24 (bug fix) OSX [text] image display & scrolling (culler,walzer)
|
||||
|
||||
2014-08-01 (bug fix) OSX font config crash (rob@bitkeeper)
|
||||
|
||||
--- Released 8.5.16, August 25, 2014 --- http://core.tcl.tk/tk/ for details
|
||||
--- Released 8.6.2, August 27, 2014 --- http://core.tcl.tk/tk/ for details
|
||||
|
||||
2014-08-27 (bug) Cocoa: Crash after [$button destroy] (walzer)
|
||||
|
||||
@@ -6964,7 +7134,7 @@ Many revisions to better support a Cygwin environment (nijtmans)
|
||||
|
||||
2014-10-14 (bug)[fb35eb] fix PNG transparency appearance (walton,culler)
|
||||
|
||||
--- Released 8.5.17, October 25, 2014 --- http://core.tcl.tk/tk/ for details
|
||||
2014-10-18 (feature)[TIP 432] Win: updated file dialogs (nadkarni)
|
||||
|
||||
2014-10-26 Support for Windows 10 (nijtmans)
|
||||
|
||||
@@ -6972,21 +7142,31 @@ Many revisions to better support a Cygwin environment (nijtmans)
|
||||
|
||||
2014-10-30 (bug)[3417012] [scale -digits $bigValue] segfault (vogel)
|
||||
|
||||
2014-11-06 (bug)[9d72dc] memleak in Cocoa buttons (revol)
|
||||
|
||||
2014-11-07 (bug)[3529885] [scale] handling of negative resolution (vogel)
|
||||
|
||||
--- Released 8.6.3, November 12, 2014 --- http://core.tcl.tk/tk/ for details
|
||||
|
||||
2014-11-14 (bug)[d43a10] shimmer-related crash in [tk_getOpenFile] (nadkarni)
|
||||
|
||||
2014-11-23 (bug)[1c0d6e] Win build trouble with SIGDN (keene)
|
||||
|
||||
2014-12-03 (bug)[4a0451] [tk_getOpenFile] result (nadkarni)
|
||||
|
||||
2014-12-13 fix header files installation on OS X (houben)
|
||||
|
||||
2015-01-02 (bug) Stop bit loss in [winfo id] on 64-bit Cocoa (porter)
|
||||
|
||||
2015-02-06 (bug) several fixes to elided context in [text] (vogel)
|
||||
|
||||
2015-02-06 (new feature)[TIP 433] %M binding substitution (mistachkin)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2015-02-22 (bug)[ab6dab] corrupt dashed lines in postscript (porter)
|
||||
|
||||
Tk Cocoa 2.0: App Store enabled (walzer,culler,desmera,owen,nyberg,reincke)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
--- Released 8.5.18, March 6, 2015 --- http://core.tcl.tk/tk/ for details
|
||||
--- Released 8.6.4, March 12, 2015 --- http://core.tcl.tk/tk/ for details
|
||||
|
||||
2015-03-10 (bug) Cocoa: premature image free crash (walzer)
|
||||
|
||||
@@ -6998,12 +7178,14 @@ Tk Cocoa 2.0: App Store enabled (walzer,culler,desmera,owen,nyberg,reincke)
|
||||
|
||||
2015-05-05 (bug)[06c3fc] PNG alpha error corrupted output file (gauthier,porter)
|
||||
|
||||
2015-05-20 (bug)[dece63] various mem corruptions in images (mic42,porter)
|
||||
|
||||
2015-05-24 (bug)[53f8fc] panedwindow geometry management (vogel)
|
||||
|
||||
2015-05-26 (bug)[1641721] tk_getOpenFile symlink display doubled (nijtmans)
|
||||
|
||||
2015-06-01 (bug)[d7bad5][2368195][3592454][1714535][1292219][3592454]
|
||||
panedwindow fixes (vogel)
|
||||
panedwindow fixes (vogel)
|
||||
|
||||
2015-06-25 (bug)[805cff] Tk_ConfigureWidget() segfault (aspect,nijtmans)
|
||||
|
||||
@@ -7015,8 +7197,14 @@ Tk Cocoa 2.0: App Store enabled (walzer,culler,desmera,owen,nyberg,reincke)
|
||||
|
||||
2015-08-20 (bug)[00189c] MSVC 14: semi-static UCRT support (dower,nijtmans)
|
||||
|
||||
2015-09-13 (bug)[cc0ba3] PNG read buffer overflow (maxjarek,porter)
|
||||
|
||||
2015-09-29 (bug)[1501749] Crash embedded window delete bound to <Map> (vogel)
|
||||
|
||||
2015-10-04 (license) Replace icons that lacked clear free license (cowals)
|
||||
|
||||
2015-10-06 (bug)[46c83f] Win: tk_getOpenFile -initialdir (koend,nadkarni)
|
||||
|
||||
2015-10-08 (new feature)[TIP 437] New panedwindow options (vogel)
|
||||
|
||||
2015-10-09 (bug)[1669632] [text] autoseparator placement (nash,vogel)
|
||||
@@ -7067,8 +7255,243 @@ Tk Cocoa 2.0: App Store enabled (walzer,culler,desmera,owen,nyberg,reincke)
|
||||
|
||||
2016-01-12 (bug)[2049429] get more $text options from database (vogel)
|
||||
|
||||
2016-01-22 (TIP 441) New option [listbox ... -justify] (vogel)
|
||||
|
||||
2016-01-25 (bug) OBOE in ttk::notebook options parsing (bromley,english)
|
||||
|
||||
2016-02-08 (enhance) [option readile] expects utf-8 file (oehlmann,nijtmans)
|
||||
|
||||
2016-02-08 (bug) crash in [$text delete] (griffin,vogel)
|
||||
|
||||
Tk Cocoa 2.0: More drawing internals refinements (culler,walzer)
|
||||
|
||||
--- Released 8.5.19, February 12, 2016 --- http://core.tcl.tk/tk/ for details
|
||||
--- Released 8.6.5, February 29, 2016 --- http://core.tcl.tk/tk/ for details
|
||||
|
||||
2016-03-07 (bug)[3137232] spinbox teardown hygiene (vogel)
|
||||
|
||||
2016-03-07 (bug)[2981253] spinbox rapid button action (vogel)
|
||||
|
||||
2016-03-07 (bug)[2262543] scale initialization callbacks (vogel)
|
||||
|
||||
2016-03-07 (bug)[e9112e] incomplete [wm forget] (vogel)
|
||||
|
||||
2016-03-11 (bug)[d95e5d] <Map> from hidden panes (vogel)
|
||||
|
||||
2016-03-20 (TIP 443) More configuration options for text tags (vogel)
|
||||
|
||||
2016-03-20 (bug)[487861] menu: cascade/accelerator appearance (vogel)
|
||||
|
||||
2016-03-27 (bug)[1192095] active index from toplevel menus (vogel)
|
||||
|
||||
2016-03-27 (bug)[18c08d] revised final newline behavior in [text] (vogel)
|
||||
*** POTENTIAL INCOMPATIBILITY ***
|
||||
|
||||
2016-04-29 (bug)[fd3a4d] <<Modified>> delivery to text peers (vogel)
|
||||
|
||||
2016-05-03 (bug)[b36218,011706] event reentrancy / widget destruction (vogel)
|
||||
|
||||
2016-05-12 (bug)[64261b] mouse events after double click (nadmarki,nijtmans)
|
||||
|
||||
2016-05-18 (bug)[545f10] Xft color font speed (bonfield,davies,girffin,vogel)
|
||||
|
||||
2016-05-25 (bug)[109865] event reentrancy / widget destruction (vogel)
|
||||
|
||||
2016-05-30 (TIP 446)[1273358] [$text edit (canundo|canredo)] (vogel)
|
||||
|
||||
2016-05-30 (bug)[79549a] crash in mouse pointer warping (vogel)
|
||||
|
||||
2016-06-22 (bug)[787adc] Modernize Tk_Init() (porter)
|
||||
|
||||
2016-07-06 (bug) Aqua: excess lable padding (lanam,walzer)
|
||||
|
||||
2016-07-08 (bug) Aqua: bitmap distortion (culler,walzer)
|
||||
|
||||
2016-07-15 (bug) Aqua/Retina: fix alpha rendering of images (culler,walzer)
|
||||
|
||||
2016-07-17 (bug)[c84f66] Aqua: crash: overflow in geometry calc (culler,walzer)
|
||||
|
||||
2016-07-21 (bug)[450bb0] Aqua: memory corruption from [tk busy] (porter)
|
||||
|
||||
--- Released 8.6.6, July 27, 2016 --- http://core.tcl.tk/tk/ for details
|
||||
|
||||
2016-08-23 (bug)[a2abc4] Wrong warp cursor position on 2nd display (vogel)
|
||||
|
||||
2016-08-29 (bug)[fa3229] menu-38.1 (calvo,vogel)
|
||||
|
||||
2016-08-29 (bug)[2cf3d6] button-5.24 (vogel)
|
||||
|
||||
2016-09-04 (bug)[1534455,2945130] Key release events get _L vs _R right. (vogel)
|
||||
|
||||
2016-09-10 (bug)[8c4216] listbox-4.1 (vogel)
|
||||
|
||||
2016-09-10 (bug)[eb2681] listbox-13.1 (vogel)
|
||||
|
||||
2016-09-21 (bug)[3126428] ttk::button react to image change (thoyts)
|
||||
|
||||
2016-10-09 (bug)[1082213] wrapped text don't start lines with whitespace (vogel)
|
||||
|
||||
2016-10-12 (bug)[3217462] tri-state button on non-native theme (vogel)
|
||||
|
||||
2016-10-30 (bug)[3588460] Fix file dialog -typevariable (vogel)
|
||||
|
||||
2016-11-01 (bug)[e36963] event generate .e <diaeresis> (matthias,vogel)
|
||||
|
||||
2016-11-05 (bug)[6aea69] grid-23 (danckaert,vogel)
|
||||
|
||||
2016-11-18 (bug)[f60c54] combobox-3 (panza,vogel)
|
||||
|
||||
2017-01-03 (bug)[f32502] crash drawing many dashed objects (reithofer,werner)
|
||||
|
||||
2017-01-05 (bug)[dac92f] text-2.[89] (vogel)
|
||||
|
||||
2017-01-07 (bug)[3df559] OSX: Negative bbox width (vogel)
|
||||
|
||||
2017-01-07 (bug)[28a453] OSX: text widget index OBOE (vogel)
|
||||
|
||||
2017-01-07 (bug)[c12af7] OSX: text-21.1 (vogel)
|
||||
|
||||
2017-01-08 (bug)[7a838c] X11 ring buffer overflow (werner)
|
||||
|
||||
2017-01-11 (bug)[d4fb4e] imgPhoto-4.75 (nijtmans)
|
||||
|
||||
2017-01-18 (bug)[fab5fe] OSX: repair textDisp failures (vogel)
|
||||
|
||||
2017-01-23 (bug)[89a638] OSX: textDisp-15.8 (vogel)
|
||||
|
||||
2017-01-25 (bug)[1403ea] Limits on text line size on Windows (spjuth)
|
||||
|
||||
2017-02-05 (bug)[ae32eb] textDisp fails in text custom config (vogel)
|
||||
|
||||
2017-02-05 (bug)[7d967c] crash after IME restart (lanam,nijtmans)
|
||||
|
||||
2017-02-22 (bug)[c492c9] disabled combobox arrow appearance (danckaert)
|
||||
|
||||
2017-03-06 (bug)[6b3644] Fix -alpha for 16-bit color PNG (LemonMan)
|
||||
|
||||
2017-03-11 (bug)[775273] artifacts on Ubuntu 16.10+ (nemethi)
|
||||
|
||||
2n017-03-26 (TIP 464) Win multimedia keys support (fassel,vogel)
|
||||
|
||||
2017-03-29 (bug)[28a3c3] test BTree memleaks plugged (anonymous)
|
||||
|
||||
2017-04-06 (bug)[db8c54] Stop freed mem access in warp pointer callback (porter)
|
||||
|
||||
2017-04-07 (bugs) Fix calculation of ttk::notebook tab widths (vogel)
|
||||
|
||||
2017-04-07 (bug)[291296] notebook tab management (decoster)
|
||||
|
||||
2017-04-08 (bug)[f0188a] Win reject invalid hex color codes (bachmann)
|
||||
|
||||
2017-04-10 (bug)[3f323b] variable struct size on XCode 8.3.1 (auriocus)
|
||||
|
||||
2017-04-20 (bug)[061bf9] OSX scrollbar draw position (reincke,walzer,joye)
|
||||
|
||||
2017-05-01 (bug) restore -initialfile for OSX file dialogs (reincke,gollwitzer)
|
||||
|
||||
2017-05-06 (bug) OSX file dialog type filters (walzer)
|
||||
|
||||
2017-05-10 (bug)[a5ba1c] race condition on Win clipboard cleanup (donchenko)
|
||||
|
||||
2017-05-18 (bug)[2433781] center image on button (cramer)
|
||||
|
||||
2017-05-19 (bug)[434d29] type mismatch with recent Xft (nijtmans,werner)
|
||||
|
||||
2017-06-02 (bug)[bc43fd] paneconfigure get pane heights right (vogel)
|
||||
|
||||
2017-06-21 (bug)[adc028] menu avoid unreleasable global grab (nash)
|
||||
|
||||
2017-06-30 (bug)[92e028,c5eb90] User switch forced theme reset (lanam)
|
||||
|
||||
2017-06-30 (bug)[62c5b7] segfault in [text] replace (werner)
|
||||
|
||||
2017-07-03 (bug)[8afc6c] OSX crash in save/open dialogs (simpson,walzer)
|
||||
|
||||
2017-08-02 (bug)[b601ce] Resource exhaustion processing corrupt GIF (nash)
|
||||
|
||||
2017-08-03 (bug)[9eab54] Fix -initialdir for OSX file dialogs (gollwitzer)
|
||||
|
||||
2017-08-08 (bug)[28d0b8] Follow ICCCM advice on X selection protocol (donchenko)
|
||||
|
||||
2017-08-08 (bug)[4966ca] Scidb race in notebook tab selection (cramer)
|
||||
|
||||
--- Released 8.6.7, August 9, 2017 --- http://core.tcl.tk/tk/ for details
|
||||
|
||||
2017-08-24 (bug)[f1a3ca] Memory leak in [text] B-tree (edhume3)
|
||||
|
||||
2017-08-24 (bug)[ee40fd] Report [console] init errors (the)
|
||||
|
||||
2017-08-24 (bug)[3295446] Improve history visibility in [console] (goth)
|
||||
|
||||
2017-08-24 (bug) canvas closed polylines fully honor -joinstyle (vogel)
|
||||
|
||||
2017-08-24 (bug)[cc42cc] out of mem crash in tests imgPhoto-18.* (vogel)
|
||||
|
||||
2017-09-16 (bug)[3406785] fix coords rounding when drawing canvas items (vogel)
|
||||
|
||||
2017-09-24 (bug)[8277e1] linux fontchooser sync with available fonts (vogel)
|
||||
|
||||
2017-09-24 (bug)[5239fd] Segfault copying a photo image to itself (bachmann)
|
||||
|
||||
2017-09-24 (bug)[514ff6] canvas rotated text overlap detection (vogel)
|
||||
|
||||
2017-09-24 (bug)[1e0db2] canvas rchars artifacts (bruchie,vogel)
|
||||
|
||||
2017-10-07 (bug)[d9fdfa] display of Long non-wrapped lines in text (cramer)
|
||||
|
||||
2017-10-07 (bug)[dd9667] text anchor not set (vogel)
|
||||
|
||||
2017-10-11 (bugs) memleaks and other changes for macOS 10.13 support (culler)
|
||||
|
||||
2017-10-11 (bug)[111de2] macOS colorspace improvement (walzer,culler)
|
||||
|
||||
2017-10-13 (bug) macOS scrolling issues (culler)
|
||||
|
||||
2017-10-15 (bug) clipping regions in scrolling and drawing on macOS (culler)
|
||||
|
||||
2017-10-15 (bug) macOS redraw artifacts (culler)
|
||||
|
||||
2017-10-22 (bug)[bb6b40] ::tk::AmpMenuArgs and 'entryconf' (vogel)
|
||||
|
||||
2017-10-22 (bug)[55b95f] Crash [scale] with a bignum value (vogel)
|
||||
|
||||
2017-10-28 (bug)[ce62c8] text-37.1 fails (vogel)
|
||||
|
||||
2017-11-03 (bug)[0ef1c5] OS X - tests menu-22.[345] hang (vogel)
|
||||
|
||||
2017-11-04 (bug)[c8c52b] repair OBOE in menu.test on macOS (vogel)
|
||||
|
||||
2017-11-11 (feature) Implement [wm_iconphoto] on macOS (walzer)
|
||||
|
||||
2017-11-11 (bug) display of embedded toplevels (culler)
|
||||
|
||||
2017-11-19 (bug)[73ba07] Correct property type for MULTIPLE conversion (dpb)
|
||||
|
||||
2017-11-20 (bug) Memory leak in tkImgPhoto.c. (werner)
|
||||
|
||||
2017-11-21 (bug) Defeat zombie toplevels (culler)
|
||||
|
||||
2017-11-25 (bug) macOS resposive menu bar for command line apps (culler)
|
||||
|
||||
2017-11-25 (bug)[1c659e] support png from mac screenshots (vogel)
|
||||
|
||||
2017-11-25 (bug)[de4af1] macOS file selector "all types" setting (culler)
|
||||
|
||||
2017-11-26 (bug) [wm withdraw] on Window and Dock menus (walzer)
|
||||
|
||||
2017-11-27 (feature) Drop support for macOS 10.5 (culler)
|
||||
|
||||
2017-11-30 (bug)[164c1b] Fixes [raise] on macOS (culler)
|
||||
|
||||
2017-11-30 (bug)[13d63d] macOS support of menu -postcommand (culler)
|
||||
|
||||
2017-12-05 (bug) enable custom icon display on macOS (walzer)
|
||||
|
||||
2017-12-05 (bug)[1088805,0feb63] macOS bind failures (culler)
|
||||
|
||||
2017-12-05 (bug)[3382424] Suppress noisy messages on macOS (culler)
|
||||
|
||||
2017-12-08 (new)[TIP 477] nmake build system reform (nadkarni)
|
||||
|
||||
2017-12-18 (bug)[b77626] Make [tk busy -cursor] silent no-op on macOS (vogel)
|
||||
|
||||
--- Released 8.6.8, December 22, 2017 --- http://core.tcl.tk/tk/ for details
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
This software is copyrighted by the Regents of the University of
|
||||
California, Sun Microsystems, Inc., and other parties. The following
|
||||
terms apply to all files associated with the software unless explicitly
|
||||
disclaimed in individual files.
|
||||
California, Sun Microsystems, Inc., Scriptics Corporation, ActiveState
|
||||
Corporation, Apple Inc. and other parties. The following terms apply to
|
||||
all files associated with the software unless explicitly disclaimed in
|
||||
individual files.
|
||||
|
||||
The authors hereby grant permission to use, copy, modify, distribute,
|
||||
and license this software and its documentation for any purpose, provided
|
||||
|
||||
@@ -1,22 +0,0 @@
|
||||
/*
|
||||
* limits.h --
|
||||
*
|
||||
* This is a dummy header file to #include in Tcl when there
|
||||
* is no limits.h in /usr/include. There are only a few
|
||||
* definitions here; also see tclPort.h, which already
|
||||
* #defines some of the things here if they're not arleady
|
||||
* defined.
|
||||
*
|
||||
* Copyright (c) 1991 The Regents of the University of California.
|
||||
* Copyright (c) 1994 Sun Microsystems, Inc.
|
||||
*
|
||||
* See the file "license.terms" for information on usage and redistribution
|
||||
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
*/
|
||||
|
||||
#define LONG_MIN 0x80000000
|
||||
#define LONG_MAX 0x7fffffff
|
||||
#define INT_MIN 0x80000000
|
||||
#define INT_MAX 0x7fffffff
|
||||
#define SHRT_MIN 0x8000
|
||||
#define SHRT_MAX 0x7fff
|
||||
@@ -20,7 +20,7 @@
|
||||
#define NULL 0
|
||||
#endif
|
||||
|
||||
/*
|
||||
/*
|
||||
* Strict POSIX stuff goes here. Extensions go down below, in the ifndef
|
||||
* _POSIX_SOURCE section.
|
||||
*/
|
||||
|
||||
@@ -64,12 +64,12 @@ Interpreter to use for error reporting.
|
||||
Token for window (for all procedures except \fBTk_Get3DBorder\fR,
|
||||
must be the window for which the border was allocated).
|
||||
.AP Tcl_Obj *objPtr in
|
||||
Pointer to object whose value describes color corresponding to
|
||||
Pointer to value whose value describes color corresponding to
|
||||
background (flat areas). Illuminated edges will be brighter than
|
||||
this and shadowed edges will be darker than this.
|
||||
.AP char *colorName in
|
||||
Same as \fIobjPtr\fR except value is supplied as a string rather
|
||||
than an object.
|
||||
than a value.
|
||||
.AP Drawable drawable in
|
||||
X token for window or pixmap; indicates where graphics are to be drawn.
|
||||
Must either be the X window for \fItkwin\fR or a pixmap with the
|
||||
@@ -91,7 +91,7 @@ Width of border in pixels. Positive means border is inside rectangle
|
||||
given by \fIx\fR, \fIy\fR, \fIwidth\fR, \fIheight\fR, negative means
|
||||
border is outside rectangle.
|
||||
.AP int relief in
|
||||
Indicates 3-D position of interior of object relative to exterior;
|
||||
Indicates 3-D position of interior of value relative to exterior;
|
||||
should be \fBTK_RELIEF_RAISED\fR, \fBTK_RELIEF_SUNKEN\fR, \fBTK_RELIEF_GROOVE\fR,
|
||||
\fBTK_RELIEF_SOLID\fR, or \fBTK_RELIEF_RIDGE\fR (may also be \fBTK_RELIEF_FLAT\fR
|
||||
for \fBTk_Fill3DRectangle\fR).
|
||||
@@ -114,7 +114,7 @@ should appear higher;
|
||||
For \fBTk_Fill3DPolygon\fR, \fBTK_RELIEF_FLAT\fR may also be specified to
|
||||
indicate no difference in height.
|
||||
.AP int leftBevel in
|
||||
Non-zero means this bevel forms the left side of the object; zero means
|
||||
Non-zero means this bevel forms the left side of the value; zero means
|
||||
it forms the right side.
|
||||
.AP int leftIn in
|
||||
Non-zero means that the left edge of the horizontal bevel angles in,
|
||||
@@ -128,13 +128,12 @@ so that the bottom of the edge is farther to the left than the top.
|
||||
Zero means the edge angles out, so that the bottom is farther to the
|
||||
right than the top.
|
||||
.AP int topBevel in
|
||||
Non-zero means this bevel forms the top side of the object; zero means
|
||||
Non-zero means this bevel forms the top side of the value; zero means
|
||||
it forms the bottom side.
|
||||
.AP int which in
|
||||
Specifies which of the border's graphics contexts is desired.
|
||||
Must be \fBTK_3D_FLAT_GC\fR, \fBTK_3D_LIGHT_GC\fR, or \fBTK_3D_DARK_GC\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures provide facilities for drawing window borders in a
|
||||
@@ -153,14 +152,15 @@ darker than \fIobjPtr\fR.
|
||||
\fBTk_Alloc3DBorderFromObj\fR returns a token that may be used in later calls
|
||||
to \fBTk_Draw3DRectangle\fR. If an error occurs in allocating information
|
||||
for the border (e.g. a bogus color name was given)
|
||||
then NULL is returned and an error message is left in \fIinterp->result\fR.
|
||||
then NULL is returned and an error message is left as the result of
|
||||
interpreter \fIinterp\fR.
|
||||
If it returns successfully, \fBTk_Alloc3DBorderFromObj\fR caches
|
||||
information about the return value in \fIobjPtr\fR, which speeds up
|
||||
future calls to \fBTk_Alloc3DBorderFromObj\fR with the same \fIobjPtr\fR
|
||||
and \fItkwin\fR.
|
||||
.PP
|
||||
\fBTk_Get3DBorder\fR is identical to \fBTk_Alloc3DBorderFromObj\fR except
|
||||
that the color is specified with a string instead of an object. This
|
||||
that the color is specified with a string instead of a value. This
|
||||
prevents \fBTk_Get3DBorder\fR from caching the return value, so
|
||||
\fBTk_Get3DBorder\fR is less efficient than \fBTk_Alloc3DBorderFromObj\fR.
|
||||
.PP
|
||||
@@ -238,8 +238,8 @@ arguments that describe the rectangular area of the beveled edge
|
||||
The \fIleftBorder\fR and \fItopBorder\fR arguments indicate the
|
||||
position of the border relative to the
|
||||
.QW inside
|
||||
of the object, and
|
||||
\fIrelief\fR indicates the relief of the inside of the object relative
|
||||
of the value, and
|
||||
\fIrelief\fR indicates the relief of the inside of the value relative
|
||||
to the outside.
|
||||
\fBTk_3DVerticalBevel\fR just draws a rectangular region.
|
||||
\fBTk_3DHorizontalBevel\fR draws a trapezoidal region to generate
|
||||
@@ -290,6 +290,5 @@ with the Tk_3DBorder token for the border.
|
||||
There should be exactly one call to \fBTk_Free3DBorderFromObj\fR or
|
||||
\fBTk_Free3DBorder\fR for each call to \fBTk_Alloc3DBorderFromObj\fR
|
||||
or \fBTk_Get3DBorder\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
3D, background, border, color, depressed, illumination, object, polygon, raised, shadow, three-dimensional effect
|
||||
3D, background, border, color, depressed, illumination, value, polygon, raised, shadow, three-dimensional effect
|
||||
|
||||
@@ -23,7 +23,6 @@ Value of option.
|
||||
.AP int priority in
|
||||
Overall priority level to use for option.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
This procedure is invoked to add an option to the database
|
||||
@@ -47,6 +46,5 @@ user-specific startup files.
|
||||
.IP 80
|
||||
Used for options specified interactively after the application starts
|
||||
running.
|
||||
|
||||
.SH KEYWORDS
|
||||
class, name, option, add
|
||||
|
||||
@@ -45,7 +45,7 @@ call to \fBTk_CreateBindingTable\fR.
|
||||
Identifies object with which binding is associated.
|
||||
.AP "const char" *eventString in
|
||||
String describing event sequence.
|
||||
.AP char *script in
|
||||
.AP "const char" *script in
|
||||
Tcl script to invoke when binding triggers.
|
||||
.AP int append in
|
||||
Non-zero means append \fIscript\fR to existing script for binding,
|
||||
@@ -61,7 +61,6 @@ Number of object identifiers pointed to by \fIobjectPtr\fR.
|
||||
Points to an array of object identifiers: bindings will be considered
|
||||
for each of these objects in order from first to last.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures provide a general-purpose mechanism for creating
|
||||
@@ -112,25 +111,25 @@ select relevant events, or to disallow the use of certain events
|
||||
in bindings.
|
||||
If an error occurred while creating the binding (e.g., \fIeventString\fR
|
||||
refers to a non-existent event), then 0 is returned and an error
|
||||
message is left in \fIinterp->result\fR.
|
||||
message is left as the result of interpreter \fIinterp\fR.
|
||||
.PP
|
||||
\fBTk_DeleteBinding\fR removes from \fIbindingTable\fR the
|
||||
binding given by \fIobject\fR and \fIeventString\fR, if
|
||||
such a binding exists.
|
||||
\fBTk_DeleteBinding\fR always returns \fBTCL_OK\fR.
|
||||
In some cases it may reset \fIinterp->result\fR to the default
|
||||
In some cases it may reset the interpreter result to the default
|
||||
empty value.
|
||||
.PP
|
||||
\fBTk_GetBinding\fR returns a pointer to the script associated
|
||||
with \fIeventString\fR and \fIobject\fR in \fIbindingTable\fR.
|
||||
If no such binding exists then NULL is returned and an error
|
||||
message is left in \fIinterp->result\fR.
|
||||
message is left as the result of interpreter \fIinterp\fR.
|
||||
.PP
|
||||
\fBTk_GetAllBindings\fR returns in \fIinterp->result\fR a list
|
||||
\fBTk_GetAllBindings\fR returns in \fIinterp\fR's result a list
|
||||
of all the event strings for which there are bindings in
|
||||
\fIbindingTable\fR associated with \fIobject\fR.
|
||||
If there are no bindings for \fIobject\fR then an empty
|
||||
string is returned in \fIinterp->result\fR.
|
||||
If there are no bindings for \fIobject\fR, the result will be an empty
|
||||
string.
|
||||
.PP
|
||||
\fBTk_DeleteAllBindings\fR deletes all of the bindings in
|
||||
\fIbindingTable\fR that are associated with \fIobject\fR.
|
||||
@@ -150,6 +149,5 @@ the object is skipped.
|
||||
\fBTk_BindEvent\fR continues through all of the objects, handling
|
||||
exceptions such as errors, \fBbreak\fR, and \fBcontinue\fR as
|
||||
described in the documentation for \fBbind\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
binding, event, object, script
|
||||
|
||||
@@ -61,7 +61,6 @@ and so on.
|
||||
.AP int numPoints in
|
||||
Number of points at \fIcoordPtr\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures are called by canvas type managers to carry out
|
||||
@@ -83,38 +82,40 @@ transformation.
|
||||
of a bitmap.
|
||||
The Postscript is generated in proper image data format for Postscript,
|
||||
i.e., as data between angle brackets, one bit per pixel.
|
||||
The Postscript is appended to \fIinterp->result\fR and \fBTCL_OK\fR is returned
|
||||
unless an error occurs, in which case \fBTCL_ERROR\fR is returned and
|
||||
\fIinterp->result\fR is overwritten with an error message.
|
||||
The Postscript is appended to the result of interpreter \fIinterp\fR
|
||||
and \fBTCL_OK\fR is returned unless an error occurs, in which case
|
||||
\fBTCL_ERROR\fR is returned and the interpreter result is overwritten
|
||||
with an error message.
|
||||
.PP
|
||||
\fBTk_CanvasPsColor\fR generates Postscript to set the current color
|
||||
to correspond to its \fIcolorPtr\fR argument, taking into account any
|
||||
color map specified in the \fBpostscript\fR command.
|
||||
It appends the Postscript to \fIinterp->result\fR and returns
|
||||
\fBTCL_OK\fR unless an error occurs, in which case \fBTCL_ERROR\fR is returned and
|
||||
\fIinterp->result\fR is overwritten with an error message.
|
||||
It appends the Postscript to the interpreter \fIinterp\fR's result and returns
|
||||
\fBTCL_OK\fR unless an error occurs, in which case \fBTCL_ERROR\fR is
|
||||
returned and the interpreter's result is overwritten with an error message.
|
||||
.PP
|
||||
\fBTk_CanvasPsFont\fR generates Postscript that sets the current font
|
||||
to match \fItkFont\fR as closely as possible.
|
||||
\fBTk_CanvasPsFont\fR takes into account any font map specified
|
||||
in the \fBpostscript\fR command, and it does
|
||||
the best it can at mapping X fonts to Postscript fonts.
|
||||
It appends the Postscript to \fIinterp->result\fR and returns \fBTCL_OK\fR
|
||||
unless an error occurs, in which case \fBTCL_ERROR\fR is returned and
|
||||
\fIinterp->result\fR is overwritten with an error message.
|
||||
It appends the Postscript to interpreter \fIinterp\fR's result and
|
||||
returns \fBTCL_OK\fR unless an error occurs, in which case
|
||||
\fBTCL_ERROR\fR is returned and the interpreter's result is
|
||||
overwritten with an error message.
|
||||
.PP
|
||||
\fBTk_CanvasPsPath\fR generates Postscript to set the current path
|
||||
to the set of points given by \fIcoordPtr\fR and \fInumPoints\fR.
|
||||
It appends the resulting Postscript to \fIinterp->result\fR.
|
||||
It appends the resulting Postscript to the result of interpreter \fIinterp\fR.
|
||||
.PP
|
||||
\fBTk_CanvasPsStipple\fR generates Postscript that will fill the
|
||||
current path in stippled fashion.
|
||||
It uses \fIbitmap\fR as the stipple pattern and the current Postscript
|
||||
color; ones in the stipple bitmap are drawn in the current color, and
|
||||
zeroes are not drawn at all.
|
||||
The Postscript is appended to \fIinterp->result\fR and \fBTCL_OK\fR is
|
||||
returned, unless an error occurs, in which case \fBTCL_ERROR\fR is returned and
|
||||
\fIinterp->result\fR is overwritten with an error message.
|
||||
|
||||
The Postscript is appended to interpreter \fIinterp\fR's result and
|
||||
\fBTCL_OK\fR is returned, unless an error occurs, in which case
|
||||
\fBTCL_ERROR\fR is returned and the interpreter's result is
|
||||
overwritten with an error message.
|
||||
.SH KEYWORDS
|
||||
bitmap, canvas, color, font, path, Postscript, stipple
|
||||
|
||||
@@ -71,7 +71,6 @@ the left of this coordinate need to be redisplayed.
|
||||
Bottom edge of the region that needs redisplay. Only pixels above
|
||||
this coordinate need to be redisplayed.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures are called by canvas type managers to perform various
|
||||
@@ -86,7 +85,7 @@ canvas coordinate.
|
||||
If \fIstring\fR is a valid coordinate description then \fBTk_CanvasGetCoord\fR
|
||||
stores the corresponding canvas coordinate at *\fIdoublePtr\fR
|
||||
and returns \fBTCL_OK\fR.
|
||||
Otherwise it stores an error message in \fIinterp->result\fR and
|
||||
Otherwise it stores an error message in the interpreter result and
|
||||
returns \fBTCL_ERROR\fR.
|
||||
.PP
|
||||
\fBTk_CanvasDrawableCoords\fR is called by type managers during
|
||||
@@ -142,18 +141,18 @@ The code of a canvas type manager will not call these procedures
|
||||
directly, but will use their addresses to create a \fBTk_CustomOption\fR
|
||||
structure for the \fB\-tags\fR option. The code typically looks
|
||||
like this:
|
||||
.PP
|
||||
.CS
|
||||
static Tk_CustomOption tagsOption = {Tk_CanvasTagsParseProc,
|
||||
static const Tk_CustomOption tagsOption = {Tk_CanvasTagsParseProc,
|
||||
Tk_CanvasTagsPrintProc, (ClientData) NULL
|
||||
};
|
||||
|
||||
static Tk_ConfigSpec configSpecs[] = {
|
||||
static const Tk_ConfigSpec configSpecs[] = {
|
||||
...
|
||||
{TK_CONFIG_CUSTOM, "\-tags", (char *) NULL, (char *) NULL,
|
||||
(char *) NULL, 0, TK_CONFIG_NULL_OK, &tagsOption},
|
||||
{TK_CONFIG_CUSTOM, "\-tags", NULL, NULL,
|
||||
NULL, 0, TK_CONFIG_NULL_OK, &tagsOption},
|
||||
...
|
||||
};
|
||||
.CE
|
||||
|
||||
.SH KEYWORDS
|
||||
canvas, focus, item type, redisplay, selection, type manager
|
||||
|
||||
@@ -20,7 +20,6 @@ Tk_CanvasTextInfo *
|
||||
.AP Tk_Canvas canvas in
|
||||
A token that identifies a particular canvas widget.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
Textual canvas items are somewhat more complicated to manage than
|
||||
@@ -47,7 +46,7 @@ typedef struct Tk_CanvasTextInfo {
|
||||
Tk_Item *\fIfocusItemPtr\fR;
|
||||
int \fIgotFocus\fR;
|
||||
int \fIcursorOn\fR;
|
||||
} Tk_CanvasTextInfo;
|
||||
} \fBTk_CanvasTextInfo\fR;
|
||||
.CE
|
||||
The \fBselBorder\fR field identifies a Tk_3DBorder that should be
|
||||
used for drawing the background under selected text.
|
||||
@@ -97,6 +96,5 @@ anchor, as determined by \fIselItemPtr\fR or \fIanchorItemPtr\fR).
|
||||
If all of the selected text in the item is deleted, the item should
|
||||
set \fIselItemPtr\fR to NULL to indicate that there is no longer a
|
||||
selection.
|
||||
|
||||
.SH KEYWORDS
|
||||
canvas, focus, insertion cursor, selection, selection anchor, text
|
||||
|
||||
@@ -31,10 +31,9 @@ Conversion type for this clipboard item; has same meaning as
|
||||
.AP Atom format in
|
||||
Representation to use when data is retrieved; has same meaning as
|
||||
\fIformat\fR argument to \fBTk_CreateSelHandler\fR.
|
||||
.AP char *buffer in
|
||||
.AP "const char" *buffer in
|
||||
Null terminated string containing the data to be appended to the clipboard.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These two procedures manage the clipboard for Tk.
|
||||
@@ -43,9 +42,10 @@ once, then calling \fBTk_ClipboardAppend\fR to add data for any
|
||||
number of targets.
|
||||
.PP
|
||||
\fBTk_ClipboardClear\fR claims the CLIPBOARD selection and frees any
|
||||
data items previously stored on the clipboard in this application.
|
||||
data items previously stored on the clipboard in this application.
|
||||
It normally returns \fBTCL_OK\fR, but if an error occurs it returns
|
||||
\fBTCL_ERROR\fR and leaves an error message in \fIinterp->result\fR.
|
||||
\fBTCL_ERROR\fR and leaves an error message in interpreter
|
||||
\fIinterp\fR's result.
|
||||
\fBTk_ClipboardClear\fR must be called before a sequence of
|
||||
\fBTk_ClipboardAppend\fR calls can be issued.
|
||||
.PP
|
||||
@@ -60,8 +60,8 @@ currently owned by the application, either
|
||||
because \fBTk_ClipboardClear\fR has not been called or because
|
||||
ownership of the clipboard has changed since the last call to
|
||||
\fBTk_ClipboardClear\fR,
|
||||
\fBTk_ClipboardAppend\fR returns \fBTCL_ERROR\fR and leaves an error message in
|
||||
\fIinterp->result\fR.
|
||||
\fBTk_ClipboardAppend\fR returns \fBTCL_ERROR\fR and leaves an error
|
||||
message in the result of interpreter \fIinterp\fR.
|
||||
.PP
|
||||
In order to guarantee atomicity, no event handling should occur
|
||||
between \fBTk_ClipboardClear\fR and the following
|
||||
@@ -71,8 +71,7 @@ this application).
|
||||
.PP
|
||||
\fBTk_ClipboardClear\fR may invoke callbacks, including arbitrary
|
||||
Tcl scripts, as a result of losing the CLIPBOARD selection, so
|
||||
any calling function should take care to be reentrant at the point
|
||||
any calling function should take care to be re-entrant at the point
|
||||
\fBTk_ClipboardClear\fR is invoked.
|
||||
|
||||
.SH KEYWORDS
|
||||
append, clipboard, clear, format, type
|
||||
|
||||
@@ -23,10 +23,9 @@ window.
|
||||
.AP Atom selection in
|
||||
The name of selection to be cleared.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_ClearSelection\fR cancels the selection specified by the atom
|
||||
\fBTk_ClearSelection\fR cancels the selection specified by the atom
|
||||
\fIselection\fR for the display containing \fItkwin\fR.
|
||||
The selection need not be in \fItkwin\fR itself or even in
|
||||
\fItkwin\fR's application.
|
||||
@@ -35,6 +34,5 @@ owns \fIselection\fR, the window will be notified and the
|
||||
selection will be cleared.
|
||||
If there is no owner for \fIselection\fR on the display, then the
|
||||
procedure has no effect.
|
||||
|
||||
.SH KEYWORDS
|
||||
clear, selection
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_ConfigureWidget 3 4.1 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -25,12 +25,12 @@ int
|
||||
.sp
|
||||
\fBTk_FreeOptions(\fIspecs, widgRec, display, flags\fB)\fR
|
||||
.SH ARGUMENTS
|
||||
.AS Tk_ConfigSpec *widgRec in/out
|
||||
.AS char *widgRec in/out
|
||||
.AP Tcl_Interp *interp in
|
||||
Interpreter to use for returning error messages.
|
||||
.AP Tk_Window tkwin in
|
||||
Window used to represent widget (needed to set up X resources).
|
||||
.AP Tk_ConfigSpec *specs in
|
||||
.AP "const Tk_ConfigSpec" *specs in
|
||||
Pointer to table specifying legal configuration options for this
|
||||
widget.
|
||||
.AP int argc in
|
||||
@@ -61,7 +61,7 @@ Display containing widget whose record is being freed; needed in
|
||||
order to free up resources.
|
||||
.BE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
.PP
|
||||
Note: \fBTk_ConfigureWidget\fR should be replaced with the new
|
||||
\fBTcl_Obj\fR based API \fBTk_SetOptions\fR. The old interface is
|
||||
retained for backward compatibility.
|
||||
@@ -89,7 +89,7 @@ to fill in fields of \fIwidgRec\fR that are not specified in \fIargv\fR.
|
||||
case it does not modify \fIinterp\fR.
|
||||
If an error
|
||||
occurs then \fBTCL_ERROR\fR is returned and \fBTk_ConfigureWidget\fR will
|
||||
leave an error message in \fIinterp->result\fR in the standard Tcl
|
||||
leave an error message in interpreter \fIinterp\fR's result in the standard Tcl
|
||||
fashion.
|
||||
In the event of an error return, some of the fields of \fIwidgRec\fR
|
||||
could already have been set, if configuration information for them
|
||||
@@ -103,14 +103,14 @@ option and has the following structure:
|
||||
.CS
|
||||
typedef struct {
|
||||
int \fItype\fR;
|
||||
char *\fIargvName\fR;
|
||||
char *\fIdbName\fR;
|
||||
char *\fIdbClass\fR;
|
||||
char *\fIdefValue\fR;
|
||||
const char *\fIargvName\fR;
|
||||
const char *\fIdbName\fR;
|
||||
const char *\fIdbClass\fR;
|
||||
const char *\fIdefValue\fR;
|
||||
int \fIoffset\fR;
|
||||
int \fIspecFlags\fR;
|
||||
Tk_CustomOption *\fIcustomPtr\fR;
|
||||
} Tk_ConfigSpec;
|
||||
const Tk_CustomOption *\fIcustomPtr\fR;
|
||||
} \fBTk_ConfigSpec\fR;
|
||||
.CE
|
||||
The \fItype\fR field indicates what type of configuration option this is
|
||||
(e.g. \fBTK_CONFIG_COLOR\fR for a color value, or \fBTK_CONFIG_INT\fR for
|
||||
@@ -174,7 +174,7 @@ legal values for \fItype\fR, and the corresponding actions, are:
|
||||
\fBTK_CONFIG_ACTIVE_CURSOR\fR
|
||||
The value
|
||||
must be an ASCII string identifying a cursor in a form
|
||||
suitable for passing to \fBTk_GetCursor\fR.
|
||||
suitable for passing to \fBTk_GetCursor\fR.
|
||||
The value is converted to a \fBTk_Cursor\fR by calling
|
||||
\fBTk_GetCursor\fR and the result is stored in the target.
|
||||
In addition, the resulting cursor is made the active cursor
|
||||
@@ -356,7 +356,6 @@ is an empty string then the target will be set to NULL.
|
||||
\fBTK_CONFIG_WINDOW\fR
|
||||
The value must be a window path name. It is translated to a
|
||||
\fBTk_Window\fR token and the token is stored in the target.
|
||||
|
||||
.SH "GROUPED ENTRIES"
|
||||
.PP
|
||||
In some cases it is useful to generate multiple resources from
|
||||
@@ -374,7 +373,6 @@ Each of the entries after the first must have a NULL value in its
|
||||
\fIargvName\fR field; this indicates that the entry is to be grouped
|
||||
with the entry that precedes it. Only the \fItype\fR and \fIoffset\fR
|
||||
fields are used from these follow-on entries.
|
||||
|
||||
.SH "FLAGS"
|
||||
.PP
|
||||
The \fIflags\fR argument passed to \fBTk_ConfigureWidget\fR is used
|
||||
@@ -434,13 +432,11 @@ once, save the value, and provide it before calling
|
||||
.TP
|
||||
\fBTK_CONFIG_OPTION_SPECIFIED\fR
|
||||
This bit is
|
||||
.VS 8.5
|
||||
deprecated. It used to be set and cleared by \fBTk_ConfigureWidget\fR
|
||||
so that callers could detect what entries were specified in
|
||||
\fIargv\fR, but it was removed because it was inherently
|
||||
thread-unsafe. Code that wishes to detect what options were specified
|
||||
should use \fBTk_SetOptions\fR instead.
|
||||
.VE 8.5
|
||||
.PP
|
||||
The \fBTK_CONFIG_MONO_ONLY\fR and \fBTK_CONFIG_COLOR_ONLY\fR flags are typically
|
||||
used to specify different default values for
|
||||
@@ -473,7 +469,6 @@ for which this entry is valid. When calling \fBTk_ConfigureWidget\fR,
|
||||
\fIflags\fR will have a single one of these bits set to select the
|
||||
entries for the desired widget type. For a working example of
|
||||
this feature, see the code in tkButton.c.
|
||||
|
||||
.SH TK_OFFSET
|
||||
.PP
|
||||
The \fBTk_Offset\fR macro is provided as a safe way of generating
|
||||
@@ -481,7 +476,6 @@ the \fIoffset\fR values for entries in Tk_ConfigSpec structures.
|
||||
It takes two arguments: the name of a type of record, and the
|
||||
name of a field in that record. It returns the byte offset of
|
||||
the named field in records of the given type.
|
||||
|
||||
.SH TK_CONFIGUREINFO
|
||||
.PP
|
||||
The \fBTk_ConfigureInfo\fR procedure may be used to obtain
|
||||
@@ -492,12 +486,12 @@ pointer to a widget record containing the current information for
|
||||
a widget (\fIwidgRec\fR), and a NULL \fIargvName\fR argument,
|
||||
\fBTk_ConfigureInfo\fR generates a string describing all of the
|
||||
configuration options for the window. The string is placed
|
||||
in \fIinterp->result\fR. Under normal circumstances
|
||||
in interpreter \fIinterp\fR's result. Under normal circumstances
|
||||
it returns \fBTCL_OK\fR; if an error occurs then it returns \fBTCL_ERROR\fR
|
||||
and \fIinterp->result\fR contains an error message.
|
||||
and the interpreter's result will contain an error message.
|
||||
.PP
|
||||
If \fIargvName\fR is NULL, then the value left in
|
||||
\fIinterp->result\fR by \fBTk_ConfigureInfo\fR
|
||||
the interpreter's result by \fBTk_ConfigureInfo\fR
|
||||
consists of a list of one or more entries, each of which describes
|
||||
one configuration option (i.e. one entry in \fIspecs\fR). Each
|
||||
entry in the list will contain either two or five values. If the
|
||||
@@ -510,27 +504,25 @@ field of \fIwidgRec\fR by calling procedures like \fBTk_NameOfColor\fR.
|
||||
.PP
|
||||
If the \fIargvName\fR argument to \fBTk_ConfigureInfo\fR is non-NULL,
|
||||
then it indicates a single option, and information is returned only
|
||||
for that option. The string placed in \fIinterp->result\fR will be
|
||||
for that option. The string placed in the interpreter's result will be
|
||||
a list containing two or five values as described above; this will
|
||||
be identical to the corresponding sublist that would have been returned
|
||||
if \fIargvName\fR had been NULL.
|
||||
.PP
|
||||
The \fIflags\fR argument to \fBTk_ConfigureInfo\fR is used to restrict
|
||||
the \fIspecs\fR entries to consider, just as for \fBTk_ConfigureWidget\fR.
|
||||
|
||||
.SH TK_CONFIGUREVALUE
|
||||
.PP
|
||||
\fBTk_ConfigureValue\fR takes arguments similar to \fBTk_ConfigureInfo\fR;
|
||||
instead of returning a list of values, it just returns the current value
|
||||
of the option given by \fIargvName\fR (\fIargvName\fR must not be NULL).
|
||||
The value is returned in \fIinterp->result\fR and \fBTCL_OK\fR is
|
||||
The value is returned in interpreter \fIinterp\fR's result and \fBTCL_OK\fR is
|
||||
normally returned as the procedure's result.
|
||||
If an error occurs in \fBTk_ConfigureValue\fR (e.g., \fIargvName\fR is
|
||||
not a valid option name), \fBTCL_ERROR\fR is returned and an error message
|
||||
is left in \fIinterp->result\fR.
|
||||
is left in the interpreter's result.
|
||||
This procedure is typically called to implement \fBcget\fR widget
|
||||
commands.
|
||||
|
||||
.SH TK_FREEOPTIONS
|
||||
.PP
|
||||
The \fBTk_FreeOptions\fR procedure may be invoked during widget cleanup
|
||||
@@ -543,7 +535,6 @@ it contains a null pointer) then no resource is freed for that
|
||||
entry.
|
||||
After freeing a resource, \fBTk_FreeOptions\fR sets the
|
||||
corresponding field of the widget record to null.
|
||||
|
||||
.SH "CUSTOM OPTION TYPES"
|
||||
.PP
|
||||
Applications can extend the built-in configuration types with additional
|
||||
@@ -554,22 +545,22 @@ typedef struct Tk_CustomOption {
|
||||
Tk_OptionParseProc *\fIparseProc\fR;
|
||||
Tk_OptionPrintProc *\fIprintProc\fR;
|
||||
ClientData \fIclientData\fR;
|
||||
} Tk_CustomOption;
|
||||
} \fBTk_CustomOption\fR;
|
||||
|
||||
typedef int Tk_OptionParseProc(
|
||||
ClientData \fIclientData\fR,
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Window \fItkwin\fR,
|
||||
char *\fIvalue\fR,
|
||||
char *\fIwidgRec\fR,
|
||||
int \fIoffset\fR);
|
||||
typedef int \fBTk_OptionParseProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Window \fItkwin\fR,
|
||||
char *\fIvalue\fR,
|
||||
char *\fIwidgRec\fR,
|
||||
int \fIoffset\fR);
|
||||
|
||||
typedef char *Tk_OptionPrintProc(
|
||||
ClientData \fIclientData\fR,
|
||||
Tk_Window \fItkwin\fR,
|
||||
char *\fIwidgRec\fR,
|
||||
int \fIoffset\fR,
|
||||
Tcl_FreeProc **\fIfreeProcPtr\fR);
|
||||
typedef const char *\fBTk_OptionPrintProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
Tk_Window \fItkwin\fR,
|
||||
char *\fIwidgRec\fR,
|
||||
int \fIoffset\fR,
|
||||
Tcl_FreeProc **\fIfreeProcPtr\fR);
|
||||
.CE
|
||||
The Tk_CustomOption structure contains three fields, which are pointers
|
||||
to the two procedures and a \fIclientData\fR value to be passed to those
|
||||
@@ -599,7 +590,7 @@ be placed. The procedure should translate the string to whatever
|
||||
form is appropriate for the option and store the value in the widget
|
||||
record. It should normally return \fBTCL_OK\fR, but if an error occurs
|
||||
in translating the string to a value then it should return \fBTCL_ERROR\fR
|
||||
and store an error message in \fIinterp->result\fR.
|
||||
and store an error message in interpreter \fIinterp\fR's result.
|
||||
.PP
|
||||
The \fIprintProc\fR procedure is called
|
||||
by \fBTk_ConfigureInfo\fR to produce a string value describing an
|
||||
@@ -622,7 +613,6 @@ Tk_CustomOption structure has been created for them, options of this
|
||||
new type may be manipulated with Tk_ConfigSpec entries whose \fItype\fR
|
||||
fields are \fBTK_CONFIG_CUSTOM\fR and whose \fIcustomPtr\fR fields point
|
||||
to the Tk_CustomOption structure.
|
||||
|
||||
.SH EXAMPLES
|
||||
.PP
|
||||
Although the explanation of \fBTk_ConfigureWidget\fR is fairly
|
||||
@@ -633,10 +623,8 @@ The library implementation of frames
|
||||
(tkFrame.c) has a simple configuration table, and the library
|
||||
implementation of buttons (tkButton.c) has a much more complex
|
||||
table that uses many of the fancy \fIspecFlags\fR mechanisms.
|
||||
|
||||
.SH "SEE ALSO"
|
||||
Tk_SetOptions(3)
|
||||
|
||||
.SH KEYWORDS
|
||||
anchor, bitmap, boolean, border, cap style, color, configuration options,
|
||||
cursor, custom, double, font, integer, join style, justify, millimeters,
|
||||
|
||||
@@ -25,7 +25,6 @@ Y-coordinate (in root window coordinates).
|
||||
.AP Tk_Window tkwin in
|
||||
Token for window that identifies application.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_CoordsToWindow\fR locates the window that contains a given point.
|
||||
@@ -44,6 +43,5 @@ which window contains the mouse cursor: if a parent and a child both
|
||||
contain the point then the child gets preference, and if two siblings
|
||||
both contain the point then the highest one in the stacking order
|
||||
(i.e. the one that's visible on the screen) gets preference.
|
||||
|
||||
.SH KEYWORDS
|
||||
containing, coordinates, root window
|
||||
|
||||
@@ -20,10 +20,8 @@ Tk_CreateClientMessageHandler, Tk_DeleteClientMessageHandler \- associate proced
|
||||
.AP Tk_ClientMessageProc *proc in
|
||||
Procedure to invoke whenever a ClientMessage X event occurs on any display.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
|
||||
\fBTk_CreateClientMessageHandler\fR arranges for \fIproc\fR to be invoked
|
||||
in the future whenever a ClientMessage X event occurs that is not handled by
|
||||
\fBWM_PROTOCOL\fR. \fBTk_CreateClientMessageHandler\fR is intended for use
|
||||
@@ -39,9 +37,9 @@ call \fBTk_HandleEvent\fR, such as \fBTk_DoOneEvent\fR or
|
||||
\fIProc\fR should have arguments and result that match the
|
||||
type \fBTk_ClientMessageProc\fR:
|
||||
.CS
|
||||
typedef int Tk_ClientMessageProc(
|
||||
Tk_Window \fItkwin\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
typedef int \fBTk_ClientMessageProc\fR(
|
||||
Tk_Window \fItkwin\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
.CE
|
||||
The \fItkwin\fR parameter to \fIproc\fR is the Tk window which is
|
||||
associated with this event. \fIEventPtr\fR is a pointer to the X event.
|
||||
@@ -62,6 +60,5 @@ finds that matches the \fIproc\fR argument. If no such handler exists,
|
||||
then \fBTk_DeleteClientMessageHandler\fR returns without doing anything.
|
||||
Although Tk supports it, it's probably a bad idea to have more than one
|
||||
callback with the same \fIproc\fR argument.
|
||||
|
||||
.SH KEYWORDS
|
||||
bind, callback, event, handler
|
||||
|
||||
@@ -72,9 +72,9 @@ made when the handler was active (see below for more information).
|
||||
\fIProc\fR should have arguments and result that match the
|
||||
following type:
|
||||
.CS
|
||||
typedef int Tk_ErrorProc(
|
||||
ClientData \fIclientData\fR,
|
||||
XErrorEvent *\fIerrEventPtr\fR);
|
||||
typedef int \fBTk_ErrorProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
XErrorEvent *\fIerrEventPtr\fR);
|
||||
.CE
|
||||
The \fIclientData\fR parameter to \fIproc\fR is a copy of the \fIclientData\fR
|
||||
argument given to \fBTcl_CreateErrorHandler\fR when the callback
|
||||
@@ -136,6 +136,5 @@ handlers deleted before the \fBXSync\fR call.
|
||||
For the Tk error handling mechanism to work properly, it is essential
|
||||
that application code never calls \fBXSetErrorHandler\fR directly;
|
||||
applications should use only \fBTk_CreateErrorHandler\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
callback, error, event, handler
|
||||
|
||||
@@ -24,7 +24,6 @@ Procedure to invoke whenever any X event occurs on any display.
|
||||
.AP ClientData clientData in
|
||||
Arbitrary one-word value to pass to \fIproc\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_CreateGenericHandler\fR arranges for \fIproc\fR to be
|
||||
@@ -45,9 +44,9 @@ call \fBTk_HandleEvent\fR, such as \fBTk_DoOneEvent\fR or
|
||||
\fIProc\fR should have arguments and result that match the
|
||||
type \fBTk_GenericProc\fR:
|
||||
.CS
|
||||
typedef int Tk_GenericProc(
|
||||
ClientData \fIclientData\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
typedef int \fBTk_GenericProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
.CE
|
||||
The \fIclientData\fR parameter to \fIproc\fR is a copy of the \fIclientData\fR
|
||||
argument given to \fBTk_CreateGenericHandler\fR when the callback
|
||||
|
||||
@@ -21,11 +21,12 @@ ClientData
|
||||
.sp
|
||||
\fBTk_InitImageArgs\fR(\fIinterp, argc, argvPtr\fR)
|
||||
.SH ARGUMENTS
|
||||
.AS Tk_ImageType *typePtrPtr
|
||||
.AP Tk_ImageType *typePtr in
|
||||
.AS "const Tk_ImageType" *typePtrPtr
|
||||
.AP "const Tk_ImageType" *typePtr in
|
||||
Structure that defines the new type of image.
|
||||
Must be static: a
|
||||
For Tk 8.4 and earlier this must be static: a
|
||||
pointer to this structure is retained by the image code.
|
||||
In Tk 8.5, this limitation was relaxed.
|
||||
.AP Tcl_Interp *interp in
|
||||
Interpreter in which image was created.
|
||||
.AP "const char" *name in
|
||||
@@ -38,7 +39,6 @@ Number of arguments
|
||||
.AP char ***argvPtr in/out
|
||||
Pointer to argument list
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_CreateImageType\fR is invoked to define a new kind of image.
|
||||
@@ -59,13 +59,13 @@ the name of the image type and pointers to five procedures provided
|
||||
by the image manager to deal with images of this type:
|
||||
.CS
|
||||
typedef struct Tk_ImageType {
|
||||
char *\fIname\fR;
|
||||
const char *\fIname\fR;
|
||||
Tk_ImageCreateProc *\fIcreateProc\fR;
|
||||
Tk_ImageGetProc *\fIgetProc\fR;
|
||||
Tk_ImageDisplayProc *\fIdisplayProc\fR;
|
||||
Tk_ImageFreeProc *\fIfreeProc\fR;
|
||||
Tk_ImageDeleteProc *\fIdeleteProc\fR;
|
||||
} Tk_ImageType;
|
||||
} \fBTk_ImageType\fR;
|
||||
.CE
|
||||
The fields of this structure will be described in later subsections
|
||||
of this entry.
|
||||
@@ -92,7 +92,6 @@ option specified for a widget or canvas item.
|
||||
.PP
|
||||
The following subsections describe the fields of a Tk_ImageType
|
||||
in more detail.
|
||||
|
||||
.SS NAME
|
||||
.PP
|
||||
\fItypePtr->name\fR provides a name for the image type.
|
||||
@@ -101,21 +100,21 @@ in \fBimage create\fR commands to create images of the new
|
||||
type.
|
||||
If there already existed an image type by this name then
|
||||
the new image type replaces the old one.
|
||||
|
||||
.SS CREATEPROC
|
||||
.PP
|
||||
\fItypePtr->createProc\fR provides the address of a procedure for
|
||||
Tk to call whenever \fBimage create\fR is invoked to create
|
||||
an image of the new type.
|
||||
\fItypePtr->createProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef int Tk_ImageCreateProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
char *\fIname\fR,
|
||||
int \fIobjc\fR,
|
||||
Tcl_Obj *const \fIobjv\fR[],
|
||||
Tk_ImageType *\fItypePtr\fR,
|
||||
Tk_ImageMaster \fImaster\fR,
|
||||
ClientData *\fImasterDataPtr\fR);
|
||||
typedef int \fBTk_ImageCreateProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
const char *\fIname\fR,
|
||||
int \fIobjc\fR,
|
||||
Tcl_Obj *const \fIobjv\fR[],
|
||||
const Tk_ImageType *\fItypePtr\fR,
|
||||
Tk_ImageMaster \fImaster\fR,
|
||||
ClientData *\fImasterDataPtr\fR);
|
||||
.CE
|
||||
The \fIinterp\fR argument is the interpreter in which the \fBimage\fR
|
||||
command was invoked, and \fIname\fR is the name for the new image,
|
||||
@@ -141,16 +140,15 @@ it should return \fBTCL_OK\fR.
|
||||
.PP
|
||||
\fIcreateProc\fR should call \fBTk_ImageChanged\fR in order to set the
|
||||
size of the image and request an initial redisplay.
|
||||
|
||||
.SS GETPROC
|
||||
.PP
|
||||
\fItypePtr->getProc\fR is invoked by Tk whenever a widget
|
||||
calls \fBTk_GetImage\fR to use a particular image.
|
||||
This procedure must match the following prototype:
|
||||
.CS
|
||||
typedef ClientData Tk_ImageGetProc(
|
||||
Tk_Window \fItkwin\fR,
|
||||
ClientData \fImasterData\fR);
|
||||
typedef ClientData \fBTk_ImageGetProc\fR(
|
||||
Tk_Window \fItkwin\fR,
|
||||
ClientData \fImasterData\fR);
|
||||
.CE
|
||||
The \fItkwin\fR argument identifies the window in which the
|
||||
image will be used and \fImasterData\fR is the value
|
||||
@@ -162,23 +160,22 @@ display the image in the given window.
|
||||
is typically the address of the instance data structure.
|
||||
Tk will pass this value back to the image manager when invoking
|
||||
its \fIdisplayProc\fR and \fIfreeProc\fR procedures.
|
||||
|
||||
.SS DISPLAYPROC
|
||||
.PP
|
||||
\fItypePtr->displayProc\fR is invoked by Tk whenever an image needs
|
||||
to be displayed (i.e., whenever a widget calls \fBTk_RedrawImage\fR).
|
||||
\fIdisplayProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef void Tk_ImageDisplayProc(
|
||||
ClientData \fIinstanceData\fR,
|
||||
Display *\fIdisplay\fR,
|
||||
Drawable \fIdrawable\fR,
|
||||
int \fIimageX\fR,
|
||||
int \fIimageY\fR,
|
||||
int \fIwidth\fR,
|
||||
int \fIheight\fR,
|
||||
int \fIdrawableX\fR,
|
||||
int \fIdrawableY\fR);
|
||||
typedef void \fBTk_ImageDisplayProc\fR(
|
||||
ClientData \fIinstanceData\fR,
|
||||
Display *\fIdisplay\fR,
|
||||
Drawable \fIdrawable\fR,
|
||||
int \fIimageX\fR,
|
||||
int \fIimageY\fR,
|
||||
int \fIwidth\fR,
|
||||
int \fIheight\fR,
|
||||
int \fIdrawableX\fR,
|
||||
int \fIdrawableY\fR);
|
||||
.CE
|
||||
The \fIinstanceData\fR will be the same as the value returned by
|
||||
\fIgetProc\fR when the instance was created.
|
||||
@@ -195,7 +192,6 @@ as specified in the most recent call to \fBTk_ImageChanged\fR.
|
||||
the image should be displayed; \fIdisplayProc\fR should display
|
||||
the given region of the image so that point (\fIimageX\fR, \fIimageY\fR)
|
||||
in the image appears at (\fIdrawableX\fR, \fIdrawableY\fR) in \fIdrawable\fR.
|
||||
|
||||
.SS FREEPROC
|
||||
.PP
|
||||
\fItypePtr->freeProc\fR contains the address of a procedure that
|
||||
@@ -206,16 +202,15 @@ in a canvas is deleted, or when the image displayed in a widget or
|
||||
canvas item is changed.
|
||||
\fIfreeProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef void Tk_ImageFreeProc(
|
||||
ClientData \fIinstanceData\fR,
|
||||
Display *\fIdisplay\fR);
|
||||
typedef void \fBTk_ImageFreeProc\fR(
|
||||
ClientData \fIinstanceData\fR,
|
||||
Display *\fIdisplay\fR);
|
||||
.CE
|
||||
The \fIinstanceData\fR will be the same as the value returned by
|
||||
\fIgetProc\fR when the instance was created, and \fIdisplay\fR
|
||||
is the display containing the window for the instance.
|
||||
\fIfreeProc\fR should release any resources associated with the
|
||||
image instance, since the instance will never be used again.
|
||||
|
||||
.SS DELETEPROC
|
||||
.PP
|
||||
\fItypePtr->deleteProc\fR is a procedure that Tk invokes when an
|
||||
@@ -225,15 +220,14 @@ Before invoking \fIdeleteProc\fR Tk will invoke \fIfreeProc\fR for
|
||||
each of the image's instances.
|
||||
\fIdeleteProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef void Tk_ImageDeleteProc(
|
||||
ClientData \fImasterData\fR);
|
||||
typedef void \fBTk_ImageDeleteProc\fR(
|
||||
ClientData \fImasterData\fR);
|
||||
.CE
|
||||
The \fImasterData\fR argument will be the same as the value
|
||||
stored in \fI*masterDataPtr\fR by \fIcreateProc\fR when the
|
||||
image was created.
|
||||
\fIdeleteProc\fR should release any resources associated with
|
||||
the image.
|
||||
|
||||
.SH TK_GETIMAGEMASTERDATA
|
||||
.PP
|
||||
The procedure \fBTk_GetImageMasterData\fR may be invoked to retrieve
|
||||
@@ -247,19 +241,19 @@ and the return value is the ClientData value returned by the
|
||||
\fIcreateProc\fR when the image was created (this is typically a
|
||||
pointer to the image master data structure). If no such image exists
|
||||
then NULL is returned and NULL is stored at \fI*typePtrPtr\fR.
|
||||
|
||||
.SH "LEGACY INTERFACE SUPPORT"
|
||||
.PP
|
||||
In Tk 8.2 and earlier, the definition of \fBTk_ImageCreateProc\fR
|
||||
was incompatibly different, with the following prototype:
|
||||
.CS
|
||||
typedef int Tk_ImageCreateProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
char *\fIname\fR,
|
||||
int \fIargc\fR,
|
||||
char **\fIargv\fR,
|
||||
Tk_ImageType *\fItypePtr\fR,
|
||||
Tk_ImageMaster \fImaster\fR,
|
||||
ClientData *\fImasterDataPtr\fR);
|
||||
typedef int \fBTk_ImageCreateProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
char *\fIname\fR,
|
||||
int \fIargc\fR,
|
||||
char **\fIargv\fR,
|
||||
Tk_ImageType *\fItypePtr\fR,
|
||||
Tk_ImageMaster \fImaster\fR,
|
||||
ClientData *\fImasterDataPtr\fR);
|
||||
.CE
|
||||
Legacy programs and libraries dating from those days may still
|
||||
contain code that defines extended Tk image types using the old
|
||||
@@ -283,9 +277,7 @@ use Tk 8.4 headers and stub libraries to do so.
|
||||
.PP
|
||||
Any new code written today should not make use of the legacy
|
||||
interfaces. Expect their support to go away in Tk 9.
|
||||
|
||||
.SH "SEE ALSO"
|
||||
Tk_ImageChanged, Tk_GetImage, Tk_FreeImage, Tk_RedrawImage, Tk_SizeOfImage
|
||||
|
||||
.SH KEYWORDS
|
||||
image manager, image type, instance, master
|
||||
|
||||
@@ -44,7 +44,7 @@ NULL \fInextPtr\fR.
|
||||
.PP
|
||||
You may find it easier to understand the rest of this manual entry
|
||||
by looking at the code for an existing canvas item type such as
|
||||
bitmap (file tkCanvBmap.c) or text (tkCanvText.c).
|
||||
bitmap (in the file tkCanvBmap.c) or text (tkCanvText.c).
|
||||
The easiest way to create a new type manager is to copy the code
|
||||
for an existing type and modify it for the new type.
|
||||
.PP
|
||||
@@ -60,12 +60,13 @@ structures.
|
||||
The first data structure is a Tk_ItemType; it contains
|
||||
information such as the name of the type and pointers to
|
||||
the standard procedures implemented by the type manager:
|
||||
.PP
|
||||
.CS
|
||||
typedef struct Tk_ItemType {
|
||||
char *\fIname\fR;
|
||||
const char *\fIname\fR;
|
||||
int \fIitemSize\fR;
|
||||
Tk_ItemCreateProc *\fIcreateProc\fR;
|
||||
Tk_ConfigSpec *\fIconfigSpecs\fR;
|
||||
const Tk_ConfigSpec *\fIconfigSpecs\fR;
|
||||
Tk_ItemConfigureProc *\fIconfigProc\fR;
|
||||
Tk_ItemCoordProc *\fIcoordProc\fR;
|
||||
Tk_ItemDeleteProc *\fIdeleteProc\fR;
|
||||
@@ -82,7 +83,7 @@ typedef struct Tk_ItemType {
|
||||
Tk_ItemInsertProc *\fIinsertProc\fR;
|
||||
Tk_ItemDCharsProc *\fIdCharsProc\fR;
|
||||
Tk_ItemType *\fInextPtr\fR;
|
||||
} Tk_ItemType;
|
||||
} \fBTk_ItemType\fR;
|
||||
.CE
|
||||
.PP
|
||||
The fields of a Tk_ItemType structure are described in more detail
|
||||
@@ -92,7 +93,7 @@ argument must point to a structure with all of the fields initialized
|
||||
except \fInextPtr\fR, which Tk sets to link all the types together
|
||||
into a list.
|
||||
The structure must be in permanent memory (either statically
|
||||
allocated or dynamically allocated but never freed); Tk retains
|
||||
allocated or dynamically allocated but never freed); Tk retains
|
||||
a pointer to this structure.
|
||||
.PP
|
||||
The second data structure manipulated by a type manager is an
|
||||
@@ -102,11 +103,12 @@ All of the items of a given type generally have item records with
|
||||
the same structure, but different types usually have different
|
||||
formats for their item records.
|
||||
The first part of each item record is a header with a standard structure
|
||||
defined by Tk via the type Tk_Item; the rest of the item
|
||||
defined by Tk via the type Tk_Item; the rest of the item
|
||||
record is defined by the type manager.
|
||||
A type manager must define its item records with a Tk_Item as
|
||||
the first field.
|
||||
For example, the item record for bitmap items is defined as follows:
|
||||
.PP
|
||||
.CS
|
||||
typedef struct BitmapItem {
|
||||
Tk_Item \fIheader\fR;
|
||||
@@ -116,8 +118,9 @@ typedef struct BitmapItem {
|
||||
XColor *\fIfgColor\fR;
|
||||
XColor *\fIbgColor\fR;
|
||||
GC \fIgc\fR;
|
||||
} BitmapItem;
|
||||
} \fBBitmapItem\fR;
|
||||
.CE
|
||||
.PP
|
||||
The \fIheader\fR substructure contains information used by Tk
|
||||
to manage the item, such as its identifier, its tags, its type,
|
||||
and its bounding box.
|
||||
@@ -127,7 +130,7 @@ The type manager should not need to read or write any of the
|
||||
fields in the header except for four fields
|
||||
whose names are \fIx1\fR, \fIy1\fR, \fIx2\fR, and \fIy2\fR.
|
||||
These fields give a bounding box for the items using integer
|
||||
canvas coordinates: the item should not cover any pixels
|
||||
canvas coordinates: the item should not cover any pixels
|
||||
with x-coordinate lower than \fIx1\fR or y-coordinate
|
||||
lower than \fIy1\fR, nor should it cover any pixels with
|
||||
x-coordinate greater than or equal to \fIx2\fR or y-coordinate
|
||||
@@ -137,12 +140,12 @@ date as the item is moved and reconfigured.
|
||||
.PP
|
||||
Whenever Tk calls a procedure in a type manager it passes in a pointer
|
||||
to an item record.
|
||||
The argument is always passed as a pointer to a Tk_Item; the type
|
||||
The argument is always passed as a pointer to a Tk_Item; the type
|
||||
manager will typically cast this into a pointer to its own specific
|
||||
type, such as BitmapItem.
|
||||
.PP
|
||||
The third data structure used by type managers has type
|
||||
Tk_Canvas; it serves as an opaque handle for the canvas widget
|
||||
Tk_Canvas; it serves as an opaque handle for the canvas widget
|
||||
as a whole.
|
||||
Type managers need not know anything about the contents of this
|
||||
structure.
|
||||
@@ -150,6 +153,7 @@ A Tk_Canvas handle is typically passed in to the
|
||||
procedures of a type manager, and the type manager can pass the
|
||||
handle back to library procedures such as Tk_CanvasTkwin
|
||||
to fetch information about the canvas.
|
||||
.SH "TK_ITEMTYPE FIELDS"
|
||||
.SS NAME
|
||||
.PP
|
||||
This section and the ones that follow describe each of the fields
|
||||
@@ -160,8 +164,37 @@ in \fBcreate\fR widget commands to create items of the new
|
||||
type.
|
||||
If there already existed an item type by this name then
|
||||
the new item type replaces the old one.
|
||||
.SS "FLAGS (IN ALWAYSREDRAW)"
|
||||
.PP
|
||||
The \fItypePtr\->alwaysRedraw\fR field (so named for historic reasons)
|
||||
contains a collection of flag bits that modify how the canvas core interacts
|
||||
with the item. The following bits are defined:
|
||||
.TP
|
||||
\fB1\fR
|
||||
.
|
||||
Indicates that the item should always be redrawn when any part of the canvas
|
||||
is redrawn, rather than only when the bounding box of the item overlaps the
|
||||
area being redrawn. This is used by window items, for example, which need to
|
||||
unmap subwindows that are not on the screen.
|
||||
.TP
|
||||
\fBTK_CONFIG_OBJS\fR
|
||||
.
|
||||
Indicates that operations which would otherwise take a string (or array of
|
||||
strings) actually take a Tcl_Obj reference (or an array of such references).
|
||||
The operations to which this applies are the \fIconfigProc\fR, the
|
||||
\fIcoordProc\fR, the \fIcreateProc\fR, the \fIindexProc\fR and the
|
||||
\fIinsertProc\fR.
|
||||
.TP
|
||||
\fBTK_MOVABLE_POINTS\fR
|
||||
.VS 8.6
|
||||
Indicates that the item supports the \fIdCharsProc\fR, \fIindexProc\fR and
|
||||
\fIinsertProc\fR with the same semantics as Tk's built-in line and polygon
|
||||
types, and that hence individual coordinate points can be moved. Must not be
|
||||
set if any of the above methods is NULL.
|
||||
.VE 8.6
|
||||
.SS ITEMSIZE
|
||||
\fItypePtr->itemSize\fR gives the size in bytes of item records
|
||||
.PP
|
||||
\fItypePtr\->itemSize\fR gives the size in bytes of item records
|
||||
of this type, including the Tk_Item header.
|
||||
Tk uses this size to allocate memory space for items of the type.
|
||||
All of the item records for a given type must have the same size.
|
||||
@@ -170,31 +203,38 @@ of points for a polygon), the type manager can allocate a separate
|
||||
object of variable length and keep a pointer to it in the item record.
|
||||
.SS CREATEPROC
|
||||
.PP
|
||||
\fItypePtr->createProc\fR points to a procedure for
|
||||
\fItypePtr\->createProc\fR points to a procedure for
|
||||
Tk to call whenever a new item of this type is created.
|
||||
\fItypePtr->createProc\fR must match the following prototype:
|
||||
\fItypePtr\->createProc\fR must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef int Tk_ItemCreateProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIobjc\fR,
|
||||
Tcl_Obj* const \fIobjv\fR[]);
|
||||
typedef int \fBTk_ItemCreateProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIobjc\fR,
|
||||
Tcl_Obj *const \fIobjv\fR[]);
|
||||
.CE
|
||||
.PP
|
||||
The \fIinterp\fR argument is the interpreter in which the canvas's
|
||||
\fBcreate\fR widget command was invoked, and \fIcanvas\fR is a
|
||||
handle for the canvas widget.
|
||||
\fIitemPtr\fR is a pointer to a newly-allocated item of
|
||||
size \fItypePtr->itemSize\fR.
|
||||
size \fItypePtr\->itemSize\fR.
|
||||
Tk has already initialized the item's header (the first
|
||||
\fBsizeof(Tk_ItemType)\fR bytes).
|
||||
The \fIobjc\fR and \fIobjv\fR arguments describe all of the
|
||||
arguments to the \fBcreate\fR command after the \fItype\fR
|
||||
argument.
|
||||
For example, in the widget command
|
||||
Note that if \fBTK_CONFIG_OBJS\fR is not set in the
|
||||
\fItypePtr\->alwaysRedraw\fR field, the \fIobjv\fR parameter will actually
|
||||
contain a pointer to an array of constant strings.
|
||||
For example, in the widget command:
|
||||
.PP
|
||||
.CS
|
||||
\fB\&.c create rectangle 10 20 50 50 \-fill black\fR
|
||||
.CE
|
||||
.PP
|
||||
\fIobjc\fR will be \fB6\fR and \fIobjv\fR[0] will contain the
|
||||
integer object \fB10\fR.
|
||||
.PP
|
||||
@@ -202,7 +242,7 @@ integer object \fB10\fR.
|
||||
the type-specific parts of the item record and set an initial value
|
||||
for the bounding box in the item's header.
|
||||
It should return a standard Tcl completion code and leave an
|
||||
error message in \fIinterp->result\fR if an error occurs.
|
||||
error message in the interpreter result if an error occurs.
|
||||
If an error occurs Tk will free the item record, so \fIcreateProc\fR
|
||||
must be sure to leave the item record in a clean state if it returns an error
|
||||
(e.g., it must free any additional memory that it allocated for
|
||||
@@ -212,70 +252,84 @@ the item).
|
||||
Each type manager must provide a standard table describing its
|
||||
configuration options, in a form suitable for use with
|
||||
\fBTk_ConfigureWidget\fR.
|
||||
This table will normally be used by \fItypePtr->createProc\fR
|
||||
and \fItypePtr->configProc\fR, but Tk also uses it directly
|
||||
This table will normally be used by \fItypePtr\->createProc\fR
|
||||
and \fItypePtr\->configProc\fR, but Tk also uses it directly
|
||||
to retrieve option information in the \fBitemcget\fR and
|
||||
\fBitemconfigure\fR widget commands.
|
||||
\fItypePtr->configSpecs\fR must point to the configuration table
|
||||
\fItypePtr\->configSpecs\fR must point to the configuration table
|
||||
for this type.
|
||||
Note: Tk provides a custom option type \fBtk_CanvasTagsOption\fR
|
||||
for implementing the \fB\-tags\fR option; see an existing type
|
||||
for implementing the \fB\-tags\fR option; see an existing type
|
||||
manager for an example of how to use it in \fIconfigSpecs\fR.
|
||||
.SS CONFIGPROC
|
||||
.PP
|
||||
\fItypePtr->configProc\fR is called by Tk whenever the
|
||||
\fItypePtr\->configProc\fR is called by Tk whenever the
|
||||
\fBitemconfigure\fR widget command is invoked to change the
|
||||
configuration options for a canvas item.
|
||||
This procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef int Tk_ItemConfigureProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIobjc\fR,
|
||||
Tcl_Obj* const \fIobjv\fR[],
|
||||
int \fIflags\fR);
|
||||
typedef int \fBTk_ItemConfigureProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIobjc\fR,
|
||||
Tcl_Obj *const \fIobjv\fR[],
|
||||
int \fIflags\fR);
|
||||
.CE
|
||||
The \fIinterp\fR objument identifies the interpreter in which the
|
||||
widget command was invoked, \fIcanvas\fR is a handle for the canvas
|
||||
.PP
|
||||
The \fIinterp\fR argument identifies the interpreter in which the
|
||||
widget command was invoked, \fIcanvas\fR is a handle for the canvas
|
||||
widget, and \fIitemPtr\fR is a pointer to the item being configured.
|
||||
\fIobjc\fR and \fIobjv\fR contain the configuration options. For
|
||||
example, if the following command is invoked:
|
||||
\fIobjc\fR and \fIobjv\fR contain the configuration options.
|
||||
Note that if \fBTK_CONFIG_OBJS\fR is not set in the
|
||||
\fItypePtr\->alwaysRedraw\fR field, the \fIobjv\fR parameter will actually
|
||||
contain a pointer to an array of constant strings.
|
||||
For example, if the following command is invoked:
|
||||
.PP
|
||||
.CS
|
||||
\fB\&.c itemconfigure 2 \-fill red \-outline black\fR
|
||||
.CE
|
||||
.PP
|
||||
\fIobjc\fR is \fB4\fR and \fIobjv\fR contains the string objects \fB\-fill\fR
|
||||
through \fBblack\fR.
|
||||
\fIobjc\fR will always be an even value.
|
||||
The \fIflags\fR argument contains flags to pass to \fBTk_ConfigureWidget\fR;
|
||||
The \fIflags\fR argument contains flags to pass to \fBTk_ConfigureWidget\fR;
|
||||
currently this value is always \fBTK_CONFIG_ARGV_ONLY\fR when Tk
|
||||
invokes \fItypePtr->configProc\fR, but the type manager's \fIcreateProc\fR
|
||||
invokes \fItypePtr\->configProc\fR, but the type manager's \fIcreateProc\fR
|
||||
procedure will usually invoke \fIconfigProc\fR with different flag values.
|
||||
.PP
|
||||
\fItypePtr->configProc\fR returns a standard Tcl completion code and
|
||||
leaves an error message in \fIinterp->result\fR if an error occurs.
|
||||
\fItypePtr\->configProc\fR returns a standard Tcl completion code and
|
||||
leaves an error message in the interpreter result if an error occurs.
|
||||
It must update the item's bounding box to reflect the new configuration
|
||||
options.
|
||||
.SS COORDPROC
|
||||
.PP
|
||||
\fItypePtr->coordProc\fR is invoked by Tk to implement the \fBcoords\fR
|
||||
\fItypePtr\->coordProc\fR is invoked by Tk to implement the \fBcoords\fR
|
||||
widget command for an item.
|
||||
It must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef int Tk_ItemCoordProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIobjc\fR,
|
||||
Tcl_Obj* const \fIobjv\fR[]);
|
||||
typedef int \fBTk_ItemCoordProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIobjc\fR,
|
||||
Tcl_Obj *const \fIobjv\fR[]);
|
||||
.CE
|
||||
.PP
|
||||
The arguments \fIinterp\fR, \fIcanvas\fR, and \fIitemPtr\fR
|
||||
all have the standard meanings, and \fIobjc\fR and \fIobjv\fR
|
||||
describe the coordinate arguments.
|
||||
Note that if \fBTK_CONFIG_OBJS\fR is not set in the
|
||||
\fItypePtr\->alwaysRedraw\fR field, the \fIobjv\fR parameter will actually
|
||||
contain a pointer to an array of constant strings.
|
||||
For example, if the following widget command is invoked:
|
||||
.PP
|
||||
.CS
|
||||
\fB\&.c coords 2 30 90\fR
|
||||
.CE
|
||||
.PP
|
||||
\fIobjc\fR will be \fB2\fR and \fBobjv\fR will contain the integer objects
|
||||
\fB30\fR and \fB90\fR.
|
||||
.PP
|
||||
@@ -284,41 +338,45 @@ update the item appropriately (e.g., it must reset the bounding
|
||||
box in the item's header), and return a standard Tcl completion
|
||||
code.
|
||||
If an error occurs, \fIcoordProc\fR must leave an error message in
|
||||
\fIinterp->result\fR.
|
||||
the interpreter result.
|
||||
.SS DELETEPROC
|
||||
.PP
|
||||
\fItypePtr->deleteProc\fR is invoked by Tk to delete an item
|
||||
\fItypePtr\->deleteProc\fR is invoked by Tk to delete an item
|
||||
and free any resources allocated to it.
|
||||
It must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef void Tk_ItemDeleteProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
Display *\fIdisplay\fR);
|
||||
typedef void \fBTk_ItemDeleteProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
Display *\fIdisplay\fR);
|
||||
.CE
|
||||
.PP
|
||||
The \fIcanvas\fR and \fIitemPtr\fR arguments have the usual
|
||||
interpretations, and \fIdisplay\fR identifies the X display containing
|
||||
the canvas.
|
||||
\fIdeleteProc\fR must free up any resources allocated for the item,
|
||||
so that Tk can free the item record.
|
||||
\fIdeleteProc\fR should not actually free the item record; this will
|
||||
\fIdeleteProc\fR should not actually free the item record; this will
|
||||
be done by Tk when \fIdeleteProc\fR returns.
|
||||
.SS "DISPLAYPROC AND ALWAYSREDRAW"
|
||||
.SS "DISPLAYPROC"
|
||||
.PP
|
||||
\fItypePtr->displayProc\fR is invoked by Tk to redraw an item
|
||||
\fItypePtr\->displayProc\fR is invoked by Tk to redraw an item
|
||||
on the screen.
|
||||
It must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef void Tk_ItemDisplayProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
Display *\fIdisplay\fR,
|
||||
Drawable \fIdst\fR,
|
||||
int \fIx\fR,
|
||||
int \fIy\fR,
|
||||
int \fIwidth\fR,
|
||||
int \fIheight\fR);
|
||||
typedef void \fBTk_ItemDisplayProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
Display *\fIdisplay\fR,
|
||||
Drawable \fIdst\fR,
|
||||
int \fIx\fR,
|
||||
int \fIy\fR,
|
||||
int \fIwidth\fR,
|
||||
int \fIheight\fR);
|
||||
.CE
|
||||
.PP
|
||||
The \fIcanvas\fR and \fIitemPtr\fR arguments have the usual meaning.
|
||||
\fIdisplay\fR identifies the display containing the canvas, and
|
||||
\fIdst\fR specifies a drawable in which the item should be rendered;
|
||||
@@ -340,25 +398,28 @@ of \fIdst\fR.
|
||||
.PP
|
||||
Normally an item's \fIdisplayProc\fR is only invoked if the item
|
||||
overlaps the area being displayed.
|
||||
However, if \fItypePtr->alwaysRedraw\fR has a non-zero value, then
|
||||
\fIdisplayProc\fR is invoked during every redisplay operation,
|
||||
even if the item does not overlap the area of redisplay.
|
||||
\fIalwaysRedraw\fR should normally be set to 0; it is only
|
||||
set to 1 in special cases such as window items that need to be
|
||||
unmapped when they are off-screen.
|
||||
However, if bit zero of \fItypePtr\->alwaysRedraw\fR is 1,
|
||||
(i.e.\|
|
||||
.QW "\fItypePtr\->alwaysRedraw & 1 == 1\fR" )
|
||||
then \fIdisplayProc\fR is invoked during every redisplay operation,
|
||||
even if the item does not overlap the area of redisplay; this is useful for
|
||||
cases such as window items, where the subwindow needs to be unmapped when it
|
||||
is off the screen.
|
||||
.SS POINTPROC
|
||||
.PP
|
||||
\fItypePtr->pointProc\fR is invoked by Tk to find out how close
|
||||
\fItypePtr\->pointProc\fR is invoked by Tk to find out how close
|
||||
a given point is to a canvas item.
|
||||
Tk uses this procedure for purposes such as locating the item
|
||||
under the mouse or finding the closest item to a given point.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef double Tk_ItemPointProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
double *\fIpointPtr\fR);
|
||||
typedef double \fBTk_ItemPointProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
double *\fIpointPtr\fR);
|
||||
.CE
|
||||
.PP
|
||||
\fIcanvas\fR and \fIitemPtr\fR have the usual meaning.
|
||||
\fIpointPtr\fR points to an array of two numbers giving
|
||||
the x and y coordinates of a point.
|
||||
@@ -367,15 +428,17 @@ from the point to the item, or 0 if the point lies inside
|
||||
the item.
|
||||
.SS AREAPROC
|
||||
.PP
|
||||
\fItypePtr->areaProc\fR is invoked by Tk to find out the relationship
|
||||
\fItypePtr\->areaProc\fR is invoked by Tk to find out the relationship
|
||||
between an item and a rectangular area.
|
||||
It must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef int Tk_ItemAreaProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
double *\fIrectPtr\fR);
|
||||
typedef int \fBTk_ItemAreaProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
double *\fIrectPtr\fR);
|
||||
.CE
|
||||
.PP
|
||||
\fIcanvas\fR and \fIitemPtr\fR have the usual meaning.
|
||||
\fIrectPtr\fR points to an array of four real numbers;
|
||||
the first two give the x and y coordinates of the upper left
|
||||
@@ -386,26 +449,28 @@ the given area, 0 if it lies partially inside and partially
|
||||
outside the area, and 1 if it lies entirely inside the area.
|
||||
.SS POSTSCRIPTPROC
|
||||
.PP
|
||||
\fItypePtr->postscriptProc\fR is invoked by Tk to generate
|
||||
\fItypePtr\->postscriptProc\fR is invoked by Tk to generate
|
||||
Postscript for an item during the \fBpostscript\fR widget command.
|
||||
If the type manager is not capable of generating Postscript then
|
||||
\fItypePtr->postscriptProc\fR should be NULL.
|
||||
\fItypePtr\->postscriptProc\fR should be NULL.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef int Tk_ItemPostscriptProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIprepass\fR);
|
||||
typedef int \fBTk_ItemPostscriptProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIprepass\fR);
|
||||
.CE
|
||||
.PP
|
||||
The \fIinterp\fR, \fIcanvas\fR, and \fIitemPtr\fR arguments all have
|
||||
standard meanings; \fIprepass\fR will be described below.
|
||||
standard meanings; \fIprepass\fR will be described below.
|
||||
If \fIpostscriptProc\fR completes successfully, it should append
|
||||
Postscript for the item to the information in \fIinterp->result\fR
|
||||
Postscript for the item to the information in the interpreter result
|
||||
(e.g. by calling \fBTcl_AppendResult\fR, not \fBTcl_SetResult\fR)
|
||||
and return \fBTCL_OK\fR.
|
||||
If an error occurs, \fIpostscriptProc\fR should clear the result
|
||||
and replace its contents with an error message; then it should
|
||||
and replace its contents with an error message; then it should
|
||||
return \fBTCL_ERROR\fR.
|
||||
.PP
|
||||
Tk provides a collection of utility procedures to simplify
|
||||
@@ -427,26 +492,29 @@ In order to generate Postscript that complies with the Adobe Document
|
||||
Structuring Conventions, Tk actually generates Postscript in two passes.
|
||||
It calls each item's \fIpostscriptProc\fR in each pass.
|
||||
The only purpose of the first pass is to collect font information
|
||||
(which is done by \fBTk_CanvasPsFont\fR); the actual Postscript is
|
||||
(which is done by \fBTk_CanvasPsFont\fR); the actual Postscript is
|
||||
discarded.
|
||||
Tk sets the \fIprepass\fR argument to \fIpostscriptProc\fR to 1
|
||||
during the first pass; the type manager can use \fIprepass\fR to skip
|
||||
during the first pass; the type manager can use \fIprepass\fR to skip
|
||||
all Postscript generation except for calls to \fBTk_CanvasPsFont\fR.
|
||||
During the second pass \fIprepass\fR will be 0, so the type manager
|
||||
must generate complete Postscript.
|
||||
.SS SCALEPROC
|
||||
\fItypePtr->scaleProc\fR is invoked by Tk to rescale a canvas item
|
||||
.PP
|
||||
\fItypePtr\->scaleProc\fR is invoked by Tk to rescale a canvas item
|
||||
during the \fBscale\fR widget command.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef void Tk_ItemScaleProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
double \fIoriginX\fR,
|
||||
double \fIoriginY\fR,
|
||||
double \fIscaleX\fR,
|
||||
double \fIscaleY\fR);
|
||||
typedef void \fBTk_ItemScaleProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
double \fIoriginX\fR,
|
||||
double \fIoriginY\fR,
|
||||
double \fIscaleX\fR,
|
||||
double \fIscaleY\fR);
|
||||
.CE
|
||||
.PP
|
||||
The \fIcanvas\fR and \fIitemPtr\fR arguments have the usual meaning.
|
||||
\fIoriginX\fR and \fIoriginY\fR specify an origin relative to which
|
||||
the item is to be scaled, and \fIscaleX\fR and \fIscaleY\fR give the
|
||||
@@ -454,146 +522,171 @@ x and y scale factors.
|
||||
The item should adjust its coordinates so that a point in the item
|
||||
that used to have coordinates \fIx\fR and \fIy\fR will have new
|
||||
coordinates \fIx\(fm\fR and \fIy\(fm\fR, where
|
||||
.PP
|
||||
.CS
|
||||
\fIx\(fm = originX + scaleX*(x-originX)
|
||||
y\(fm = originY + scaleY*(y-originY)\fR
|
||||
\fIx\(fm\fR = \fIoriginX\fR + \fIscaleX\fR \(mu (\fIx\fR \(mi \fIoriginX\fR)
|
||||
\fIy\(fm\fR = \fIoriginY\fR + \fIscaleY\fR \(mu (\fIy\fR \(mi \fIoriginY\fR)
|
||||
.CE
|
||||
.PP
|
||||
\fIscaleProc\fR must also update the bounding box in the item's
|
||||
header.
|
||||
.SS TRANSLATEPROC
|
||||
\fItypePtr->translateProc\fR is invoked by Tk to translate a canvas item
|
||||
.PP
|
||||
\fItypePtr\->translateProc\fR is invoked by Tk to translate a canvas item
|
||||
during the \fBmove\fR widget command.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef void Tk_ItemTranslateProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
double \fIdeltaX\fR,
|
||||
double \fIdeltaY\fR);
|
||||
typedef void \fBTk_ItemTranslateProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
double \fIdeltaX\fR,
|
||||
double \fIdeltaY\fR);
|
||||
.CE
|
||||
.PP
|
||||
The \fIcanvas\fR and \fIitemPtr\fR arguments have the usual meaning,
|
||||
and \fIdeltaX\fR and \fIdeltaY\fR give the amounts that should be
|
||||
added to each x and y coordinate within the item.
|
||||
The type manager should adjust the item's coordinates and
|
||||
update the bounding box in the item's header.
|
||||
.SS INDEXPROC
|
||||
\fItypePtr->indexProc\fR is invoked by Tk to translate a string
|
||||
.PP
|
||||
\fItypePtr\->indexProc\fR is invoked by Tk to translate a string
|
||||
index specification into a numerical index, for example during the
|
||||
\fBindex\fR widget command.
|
||||
It is only relevant for item types that support indexable text;
|
||||
\fItypePtr->indexProc\fR may be specified as NULL for non-textual
|
||||
item types.
|
||||
It is only relevant for item types that support indexable text or coordinates;
|
||||
\fItypePtr\->indexProc\fR may be specified as NULL for non-textual
|
||||
item types if they do not support detailed coordinate addressing.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef int Tk_ItemIndexProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
char \fIindexString\fR,
|
||||
int *\fIindexPtr\fR);
|
||||
typedef int \fBTk_ItemIndexProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
Tcl_Obj *\fIindexObj\fR,
|
||||
int *\fIindexPtr\fR);
|
||||
.CE
|
||||
.PP
|
||||
The \fIinterp\fR, \fIcanvas\fR, and \fIitemPtr\fR arguments all
|
||||
have the usual meaning.
|
||||
\fIindexString\fR contains a textual description of an index,
|
||||
\fIindexObj\fR contains a textual description of an index,
|
||||
and \fIindexPtr\fR points to an integer value that should be
|
||||
filled in with a numerical index.
|
||||
Note that if \fBTK_CONFIG_OBJS\fR is not set in the
|
||||
\fItypePtr\->alwaysRedraw\fR field, the \fIindexObj\fR parameter will
|
||||
actually contain a pointer to a constant string.
|
||||
It is up to the type manager to decide what forms of index
|
||||
are supported (e.g., numbers, \fBinsert\fR, \fBsel.first\fR,
|
||||
are supported (e.g., numbers, \fBinsert\fR, \fBsel.first\fR,
|
||||
\fBend\fR, etc.).
|
||||
\fIindexProc\fR should return a Tcl completion code and set
|
||||
\fIinterp->result\fR in the event of an error.
|
||||
the interpreter result in the event of an error.
|
||||
.SS ICURSORPROC
|
||||
.PP
|
||||
\fItypePtr->icursorProc\fR is invoked by Tk during
|
||||
\fItypePtr\->icursorProc\fR is invoked by Tk during
|
||||
the \fBicursor\fR widget command to set the position of the
|
||||
insertion cursor in a textual item.
|
||||
It is only relevant for item types that support an insertion cursor;
|
||||
\fItypePtr->icursorProc\fR may be specified as NULL for item types
|
||||
\fItypePtr\->icursorProc\fR may be specified as NULL for item types
|
||||
that do not support an insertion cursor.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef void Tk_ItemCursorProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIindex\fR);
|
||||
typedef void \fBTk_ItemCursorProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIindex\fR);
|
||||
.CE
|
||||
.PP
|
||||
\fIcanvas\fR and \fIitemPtr\fR have the usual meanings, and
|
||||
\fIindex\fR is an index into the item's text, as returned by a
|
||||
previous call to \fItypePtr->insertProc\fR.
|
||||
previous call to \fItypePtr\->insertProc\fR.
|
||||
The type manager should position the insertion cursor in the
|
||||
item just before the character given by \fIindex\fR.
|
||||
Whether or not to actually display the insertion cursor is
|
||||
determined by other information provided by \fBTk_CanvasGetTextInfo\fR.
|
||||
.SS SELECTIONPROC
|
||||
.PP
|
||||
\fItypePtr->selectionProc\fR is invoked by Tk during selection
|
||||
retrievals; it must return part or all of the selected text in
|
||||
\fItypePtr\->selectionProc\fR is invoked by Tk during selection
|
||||
retrievals; it must return part or all of the selected text in
|
||||
the item (if any).
|
||||
It is only relevant for item types that support text;
|
||||
\fItypePtr->selectionProc\fR may be specified as NULL for non-textual
|
||||
\fItypePtr\->selectionProc\fR may be specified as NULL for non-textual
|
||||
item types.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef int Tk_ItemSelectionProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIoffset\fR,
|
||||
char *\fIbuffer\fR,
|
||||
int \fImaxBytes\fR);
|
||||
typedef int \fBTk_ItemSelectionProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIoffset\fR,
|
||||
char *\fIbuffer\fR,
|
||||
int \fImaxBytes\fR);
|
||||
.CE
|
||||
.PP
|
||||
\fIcanvas\fR and \fIitemPtr\fR have the usual meanings.
|
||||
\fIoffset\fR is an offset in bytes into the selection where 0 refers
|
||||
to the first byte of the selection; it identifies
|
||||
to the first byte of the selection; it identifies
|
||||
the first character that is to be returned in this call.
|
||||
\fIbuffer\fR points to an area of memory in which to store the
|
||||
requested bytes, and \fImaxBytes\fR specifies the maximum number
|
||||
of bytes to return.
|
||||
\fIselectionProc\fR should extract up to \fImaxBytes\fR characters
|
||||
from the selection and copy them to \fImaxBytes\fR; it should
|
||||
from the selection and copy them to \fImaxBytes\fR; it should
|
||||
return a count of the number of bytes actually copied, which may
|
||||
be less than \fImaxBytes\fR if there are not \fIoffset+maxBytes\fR bytes
|
||||
in the selection.
|
||||
.SS INSERTPROC
|
||||
.PP
|
||||
\fItypePtr->insertProc\fR is invoked by Tk during
|
||||
the \fBinsert\fR widget command to insert new text into a
|
||||
\fItypePtr\->insertProc\fR is invoked by Tk during
|
||||
the \fBinsert\fR widget command to insert new text or coordinates into a
|
||||
canvas item.
|
||||
It is only relevant for item types that support text;
|
||||
\fItypePtr->insertProc\fR may be specified as NULL for non-textual
|
||||
It is only relevant for item types that support the \fBinsert\fR method;
|
||||
\fItypePtr\->insertProc\fR may be specified as NULL for other
|
||||
item types.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef void Tk_ItemInsertProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIindex\fR,
|
||||
char *\fIstring\fR);
|
||||
typedef void \fBTk_ItemInsertProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIindex\fR,
|
||||
Tcl_Obj *\fIobj\fR);
|
||||
.CE
|
||||
.PP
|
||||
\fIcanvas\fR and \fIitemPtr\fR have the usual meanings.
|
||||
\fIindex\fR is an index into the item's text, as returned by a
|
||||
previous call to \fItypePtr->insertProc\fR, and \fIstring\fR
|
||||
previous call to \fItypePtr\->insertProc\fR, and \fIobj\fR
|
||||
contains new text to insert just before the character given
|
||||
by \fIindex\fR.
|
||||
Note that if \fBTK_CONFIG_OBJS\fR is not set in the
|
||||
\fItypePtr\->alwaysRedraw\fR field, the \fIobj\fR parameter will
|
||||
actually contain a pointer to a constant string to be inserted.
|
||||
If the item supports modification of the coordinates list by this
|
||||
.PP
|
||||
The type manager should insert the text and recompute the bounding
|
||||
box in the item's header.
|
||||
.SS DCHARSPROC
|
||||
.PP
|
||||
\fItypePtr->dCharsProc\fR is invoked by Tk during the \fBdchars\fR
|
||||
widget command to delete a range of text from a canvas item.
|
||||
\fItypePtr\->dCharsProc\fR is invoked by Tk during the \fBdchars\fR
|
||||
widget command to delete a range of text from a canvas item or a range of
|
||||
coordinates from a pathed item.
|
||||
It is only relevant for item types that support text;
|
||||
\fItypePtr->dCharsProc\fR may be specified as NULL for non-textual
|
||||
item types.
|
||||
\fItypePtr\->dCharsProc\fR may be specified as NULL for non-textual
|
||||
item types that do not want to support coordinate deletion.
|
||||
The procedure must match the following prototype:
|
||||
.PP
|
||||
.CS
|
||||
typedef void Tk_ItemDCharsProc(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIfirst\fR,
|
||||
int \fIlast\fR);
|
||||
typedef void \fBTk_ItemDCharsProc\fR(
|
||||
Tk_Canvas \fIcanvas\fR,
|
||||
Tk_Item *\fIitemPtr\fR,
|
||||
int \fIfirst\fR,
|
||||
int \fIlast\fR);
|
||||
.CE
|
||||
.PP
|
||||
\fIcanvas\fR and \fIitemPtr\fR have the usual meanings.
|
||||
\fIfirst\fR and \fIlast\fR give the indices of the first and last bytes
|
||||
to be deleted, as returned by previous calls to \fItypePtr->indexProc\fR.
|
||||
to be deleted, as returned by previous calls to \fItypePtr\->indexProc\fR.
|
||||
The type manager should delete the specified characters and update
|
||||
the bounding box in the item's header.
|
||||
.SH "SEE ALSO"
|
||||
|
||||
@@ -20,11 +20,10 @@ Tk_CreatePhotoImageFormat \- define new file format for photo images
|
||||
.sp
|
||||
\fBTk_CreatePhotoImageFormat\fR(\fIformatPtr\fR)
|
||||
.SH ARGUMENTS
|
||||
.AS Tk_PhotoImageFormat *formatPtr
|
||||
.AP Tk_PhotoImageFormat *formatPtr in
|
||||
.AS "const Tk_PhotoImageFormat" *formatPtr
|
||||
.AP "const Tk_PhotoImageFormat" *formatPtr in
|
||||
Structure that defines the new file format.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_CreatePhotoImageFormat\fR is invoked to define a new file format
|
||||
@@ -46,14 +45,14 @@ handler to deal with files and strings in this format. The
|
||||
Tk_PhotoImageFormat structure contains the following fields:
|
||||
.CS
|
||||
typedef struct Tk_PhotoImageFormat {
|
||||
char *\fIname\fR;
|
||||
const char *\fIname\fR;
|
||||
Tk_ImageFileMatchProc *\fIfileMatchProc\fR;
|
||||
Tk_ImageStringMatchProc *\fIstringMatchProc\fR;
|
||||
Tk_ImageFileReadProc *\fIfileReadProc\fR;
|
||||
Tk_ImageStringReadProc *\fIstringReadProc\fR;
|
||||
Tk_ImageFileWriteProc *\fIfileWriteProc\fR;
|
||||
Tk_ImageStringWriteProc *\fIstringWriteProc\fR;
|
||||
} Tk_PhotoImageFormat;
|
||||
} \fBTk_PhotoImageFormat\fR;
|
||||
.CE
|
||||
.PP
|
||||
The handler need not provide implementations of all six procedures.
|
||||
@@ -65,8 +64,7 @@ structure should be set to NULL. The handler must provide the
|
||||
\fIfileMatchProc\fR procedure if it provides the \fIfileReadProc\fR
|
||||
procedure, and the \fIstringMatchProc\fR procedure if it provides the
|
||||
\fIstringReadProc\fR procedure.
|
||||
|
||||
.SH NAME
|
||||
.SS NAME
|
||||
.PP
|
||||
\fIformatPtr->name\fR provides a name for the image type.
|
||||
Once \fBTk_CreatePhotoImageFormat\fR returns, this name may be used
|
||||
@@ -77,20 +75,20 @@ the \fB\-format\fR option. The first character of \fIformatPtr->name\fR
|
||||
must not be an uppercase character from the ASCII character set
|
||||
(that is, one of the characters \fBA\fR-\fBZ\fR). Such names are used
|
||||
only for legacy interface support (see below).
|
||||
|
||||
.SH FILEMATCHPROC
|
||||
.SS FILEMATCHPROC
|
||||
.PP
|
||||
\fIformatPtr->fileMatchProc\fR provides the address of a procedure for
|
||||
Tk to call when it is searching for an image file format handler
|
||||
suitable for reading data in a given file.
|
||||
\fIformatPtr->fileMatchProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef int Tk_ImageFileMatchProc(
|
||||
Tcl_Channel \fIchan\fR,
|
||||
const char *\fIfileName\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
int *\fIwidthPtr\fR,
|
||||
int *\fIheightPtr\fR,
|
||||
Tcl_Interp *\fIinterp\fR);
|
||||
typedef int \fBTk_ImageFileMatchProc\fR(
|
||||
Tcl_Channel \fIchan\fR,
|
||||
const char *\fIfileName\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
int *\fIwidthPtr\fR,
|
||||
int *\fIheightPtr\fR,
|
||||
Tcl_Interp *\fIinterp\fR);
|
||||
.CE
|
||||
The \fIfileName\fR argument is the name of the file containing the
|
||||
image data, which is open for reading as \fIchan\fR. The
|
||||
@@ -100,19 +98,19 @@ If the data in the file appears to be in the format supported by this
|
||||
handler, the \fIformatPtr->fileMatchProc\fR procedure should store the
|
||||
width and height of the image in *\fIwidthPtr\fR and *\fIheightPtr\fR
|
||||
respectively, and return 1. Otherwise it should return 0.
|
||||
|
||||
.SH STRINGMATCHPROC
|
||||
.SS STRINGMATCHPROC
|
||||
.PP
|
||||
\fIformatPtr->stringMatchProc\fR provides the address of a procedure for
|
||||
Tk to call when it is searching for an image file format handler for
|
||||
suitable for reading data from a given string.
|
||||
\fIformatPtr->stringMatchProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef int Tk_ImageStringMatchProc(
|
||||
Tcl_Obj *\fIdata\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
int *\fIwidthPtr\fR,
|
||||
int *\fIheightPtr\fR,
|
||||
Tcl_Interp *\fIinterp\fR);
|
||||
typedef int \fBTk_ImageStringMatchProc\fR(
|
||||
Tcl_Obj *\fIdata\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
int *\fIwidthPtr\fR,
|
||||
int *\fIheightPtr\fR,
|
||||
Tcl_Interp *\fIinterp\fR);
|
||||
.CE
|
||||
The \fIdata\fR argument points to the object containing the image
|
||||
data. The \fIformat\fR argument contains the value given for
|
||||
@@ -122,21 +120,21 @@ this handler, the \fIformatPtr->stringMatchProc\fR procedure should
|
||||
store the width and height of the image in *\fIwidthPtr\fR and
|
||||
*\fIheightPtr\fR respectively, and return 1. Otherwise it should
|
||||
return 0.
|
||||
|
||||
.SH FILEREADPROC
|
||||
.SS FILEREADPROC
|
||||
.PP
|
||||
\fIformatPtr->fileReadProc\fR provides the address of a procedure for
|
||||
Tk to call to read data from an image file into a photo image.
|
||||
\fIformatPtr->fileReadProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef int Tk_ImageFileReadProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tcl_Channel \fIchan\fR,
|
||||
const char *\fIfileName\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
PhotoHandle \fIimageHandle\fR,
|
||||
int \fIdestX\fR, int \fIdestY\fR,
|
||||
int \fIwidth\fR, int \fIheight\fR,
|
||||
int \fIsrcX\fR, int \fIsrcY\fR);
|
||||
typedef int \fBTk_ImageFileReadProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tcl_Channel \fIchan\fR,
|
||||
const char *\fIfileName\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
PhotoHandle \fIimageHandle\fR,
|
||||
int \fIdestX\fR, int \fIdestY\fR,
|
||||
int \fIwidth\fR, int \fIheight\fR,
|
||||
int \fIsrcX\fR, int \fIsrcY\fR);
|
||||
.CE
|
||||
The \fIinterp\fR argument is the interpreter in which the command was
|
||||
invoked to read the image; it should be used for reporting errors.
|
||||
@@ -151,20 +149,20 @@ coordinates (\fIsrcX\fR,\fIsrcY\fR). It is to be stored in the photo
|
||||
image with its top-left corner at coordinates
|
||||
(\fIdestX\fR,\fIdestY\fR) using the \fBTk_PhotoPutBlock\fR procedure.
|
||||
The return value is a standard Tcl return value.
|
||||
|
||||
.SH STRINGREADPROC
|
||||
.SS STRINGREADPROC
|
||||
.PP
|
||||
\fIformatPtr->stringReadProc\fR provides the address of a procedure for
|
||||
Tk to call to read data from a string into a photo image.
|
||||
\fIformatPtr->stringReadProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef int Tk_ImageStringReadProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tcl_Obj *\fIdata\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
PhotoHandle \fIimageHandle\fR,
|
||||
int \fIdestX\fR, int \fIdestY\fR,
|
||||
int \fIwidth\fR, int \fIheight\fR,
|
||||
int \fIsrcX\fR, int \fIsrcY\fR);
|
||||
typedef int \fBTk_ImageStringReadProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tcl_Obj *\fIdata\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
PhotoHandle \fIimageHandle\fR,
|
||||
int \fIdestX\fR, int \fIdestY\fR,
|
||||
int \fIwidth\fR, int \fIheight\fR,
|
||||
int \fIsrcX\fR, int \fIsrcY\fR);
|
||||
.CE
|
||||
The \fIinterp\fR argument is the interpreter in which the command was
|
||||
invoked to read the image; it should be used for reporting errors.
|
||||
@@ -179,17 +177,17 @@ coordinates (\fIsrcX\fR,\fIsrcY\fR). It is to be stored in the photo
|
||||
image with its top-left corner at coordinates
|
||||
(\fIdestX\fR,\fIdestY\fR) using the \fBTk_PhotoPutBlock\fR procedure.
|
||||
The return value is a standard Tcl return value.
|
||||
|
||||
.SH FILEWRITEPROC
|
||||
.SS FILEWRITEPROC
|
||||
.PP
|
||||
\fIformatPtr->fileWriteProc\fR provides the address of a procedure for
|
||||
Tk to call to write data from a photo image to a file.
|
||||
\fIformatPtr->fileWriteProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef int Tk_ImageFileWriteProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
const char *\fIfileName\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
Tk_PhotoImageBlock *\fIblockPtr\fR);
|
||||
typedef int \fBTk_ImageFileWriteProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
const char *\fIfileName\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
Tk_PhotoImageBlock *\fIblockPtr\fR);
|
||||
.CE
|
||||
The \fIinterp\fR argument is the interpreter in which the command was
|
||||
invoked to write the image; it should be used for reporting errors.
|
||||
@@ -204,16 +202,16 @@ after the name of the format. If appropriate, the
|
||||
\fIformatPtr->fileWriteProc\fR procedure may interpret these
|
||||
characters to specify further details about the image file.
|
||||
The return value is a standard Tcl return value.
|
||||
|
||||
.SH STRINGWRITEPROC
|
||||
.SS STRINGWRITEPROC
|
||||
.PP
|
||||
\fIformatPtr->stringWriteProc\fR provides the address of a procedure for
|
||||
Tk to call to translate image data from a photo image into a string.
|
||||
\fIformatPtr->stringWriteProc\fR must match the following prototype:
|
||||
.CS
|
||||
typedef int Tk_ImageStringWriteProc(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
Tk_PhotoImageBlock *\fIblockPtr\fR);
|
||||
typedef int \fBTk_ImageStringWriteProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
Tcl_Obj *\fIformat\fR,
|
||||
Tk_PhotoImageBlock *\fIblockPtr\fR);
|
||||
.CE
|
||||
The \fIinterp\fR argument is the interpreter in which the command was
|
||||
invoked to convert the image; it should be used for reporting errors.
|
||||
@@ -228,8 +226,8 @@ after the name of the format. If appropriate, the
|
||||
\fIformatPtr->stringWriteProc\fR procedure may interpret these
|
||||
characters to specify further details about the image file.
|
||||
The return value is a standard Tcl return value.
|
||||
|
||||
.SH "LEGACY INTERFACE SUPPORT"
|
||||
.PP
|
||||
In Tk 8.2 and earlier, the definition of all the function pointer
|
||||
types stored in fields of a \fBTk_PhotoImageFormat\fR struct were
|
||||
incompatibly different. Legacy programs and libraries dating from
|
||||
@@ -266,9 +264,7 @@ use Tk 8.4 headers and stub libraries to do so.
|
||||
.PP
|
||||
Any new code written today should not make use of the legacy
|
||||
interfaces. Expect their support to go away in Tk 9.
|
||||
|
||||
.SH "SEE ALSO"
|
||||
Tk_FindPhoto, Tk_PhotoPutBlock
|
||||
|
||||
.SH KEYWORDS
|
||||
photo image, image file
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_CreateSelHandler 3 4.0 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -44,7 +44,7 @@ requestor.
|
||||
\fBTk_CreateSelHandler\fR arranges for a particular procedure
|
||||
(\fIproc\fR) to be called whenever \fIselection\fR is owned by
|
||||
\fItkwin\fR and the selection contents are requested in the
|
||||
form given by \fItarget\fR.
|
||||
form given by \fItarget\fR.
|
||||
\fITarget\fR should be one of
|
||||
the entries defined in the left column of Table 2 of the
|
||||
X Inter-Client Communication Conventions Manual (ICCCM) or
|
||||
@@ -54,11 +54,11 @@ the selection. The most common form is STRING.
|
||||
\fIProc\fR should have arguments and result that match the
|
||||
type \fBTk_SelectionProc\fR:
|
||||
.CS
|
||||
typedef int Tk_SelectionProc(
|
||||
ClientData \fIclientData\fR,
|
||||
int \fIoffset\fR,
|
||||
char *\fIbuffer\fR,
|
||||
int \fImaxBytes\fR);
|
||||
typedef int \fBTk_SelectionProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
int \fIoffset\fR,
|
||||
char *\fIbuffer\fR,
|
||||
int \fImaxBytes\fR);
|
||||
.CE
|
||||
The \fIclientData\fR parameter to \fIproc\fR is a copy of the
|
||||
\fIclientData\fR argument given to \fBTk_CreateSelHandler\fR.
|
||||
@@ -112,6 +112,5 @@ existing handler is replaced with a new one.
|
||||
\fBTk_DeleteSelHandler\fR removes the handler given by \fItkwin\fR,
|
||||
\fIselection\fR, and \fItarget\fR, if such a handler exists.
|
||||
If there is no such handler then it has no effect.
|
||||
|
||||
.SH KEYWORDS
|
||||
format, handler, selection, target
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_CreateWindow 3 4.2 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -52,14 +52,14 @@ Name of new window, specified as path name within application
|
||||
.BE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The procedures \fBTk_CreateWindow\fR,
|
||||
The procedures \fBTk_CreateWindow\fR,
|
||||
\fBTk_CreateAnonymousWindow\fR, and \fBTk_CreateWindowFromPath\fR
|
||||
are used to create new windows for
|
||||
use in Tk-based applications. Each of the procedures returns a token
|
||||
that can be used to manipulate the window in other calls to the Tk
|
||||
library. If the window could not be created successfully, then NULL
|
||||
is returned and \fIinterp->result\fR is modified to hold an error
|
||||
message.
|
||||
is returned and the result of interpreter \fIinterp\fR is modified to
|
||||
hold an error message.
|
||||
.PP
|
||||
Tk supports two different kinds of windows: internal
|
||||
windows and top-level windows.
|
||||
@@ -86,7 +86,7 @@ which would in turn be a child of the menu bar window. A dialog box might
|
||||
have the application's main window as its parent.
|
||||
.PP
|
||||
\fBTk_CreateAnonymousWindow\fR differs from \fBTk_CreateWindow\fR in
|
||||
that it creates an unnamed window. This window will be manipulable
|
||||
that it creates an unnamed window. This window will be manipulatable
|
||||
only using C interfaces, and will not be visible to Tcl scripts. Both
|
||||
interior windows and top-level windows may be created with
|
||||
\fBTk_CreateAnonymousWindow\fR.
|
||||
@@ -141,7 +141,6 @@ but has not been mapped, so no X window exists, it is
|
||||
possible to force the creation of the X window by
|
||||
calling \fBTk_MakeWindowExist\fR. This procedure issues
|
||||
the X commands to instantiate the window given by \fItkwin\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
create, deferred creation, destroy, display, internal window,
|
||||
screen, top-level window, window
|
||||
|
||||
@@ -21,13 +21,11 @@ Interpreter for which the image was created.
|
||||
.AP "const char" *name in
|
||||
Name of the image.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_DeleteImage\fR deletes the image given by \fIinterp\fR
|
||||
and \fIname\fR, if there is one. All instances of that image
|
||||
will redisplay as empty regions. If the given image does not
|
||||
exist then the procedure has no effect.
|
||||
|
||||
.SH KEYWORDS
|
||||
delete image, image manager
|
||||
|
||||
@@ -27,12 +27,10 @@ Width of the highlight ring, in pixels.
|
||||
Drawable in which to draw the highlight; usually an offscreen
|
||||
pixmap for double buffering.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_DrawFocusHighlight\fR is a utility procedure that draws the
|
||||
traversal highlight ring for a widget.
|
||||
It is typically invoked by widgets during redisplay.
|
||||
|
||||
.SH KEYWORDS
|
||||
focus, traversal highlight
|
||||
|
||||
@@ -30,7 +30,6 @@ in the window given by \fItkwin\fR.
|
||||
.AP ClientData clientData in
|
||||
Arbitrary one-word value to pass to \fIproc\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_CreateEventHandler\fR arranges for \fIproc\fR to be
|
||||
@@ -45,9 +44,9 @@ call \fBTk_HandleEvent\fR, such as \fBTk_DoOneEvent\fR or
|
||||
\fIProc\fR should have arguments and result that match the
|
||||
type \fBTk_EventProc\fR:
|
||||
.CS
|
||||
typedef void Tk_EventProc(
|
||||
ClientData \fIclientData\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
typedef void \fBTk_EventProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
.CE
|
||||
The \fIclientData\fR parameter to \fIproc\fR is a copy of the \fIclientData\fR
|
||||
argument given to \fBTk_CreateEventHandler\fR when the callback
|
||||
@@ -72,6 +71,5 @@ automatically; in this case there is no need to call
|
||||
If multiple handlers are declared for the same type of X event
|
||||
on the same window, then the handlers will be invoked in the
|
||||
order they were created.
|
||||
|
||||
.SH KEYWORDS
|
||||
bind, callback, event, handler
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
'\" Author: Paul Mackerras (paulus@cs.anu.edu.au),
|
||||
'\" Department of Computer Science,
|
||||
'\" Australian National University.
|
||||
@@ -21,7 +21,6 @@ Tk_FindPhoto, Tk_PhotoPutBlock, Tk_PhotoPutZoomedBlock, Tk_PhotoGetImage, Tk_Pho
|
||||
Tk_PhotoHandle
|
||||
\fBTk_FindPhoto\fR(\fIinterp, imageName\fR)
|
||||
.sp
|
||||
.VS 8.5
|
||||
int
|
||||
\fBTk_PhotoPutBlock\fR(\fIinterp, handle, blockPtr, x, y, width, height,\
|
||||
compRule\fR)
|
||||
@@ -29,7 +28,6 @@ compRule\fR)
|
||||
int
|
||||
\fBTk_PhotoPutZoomedBlock\fR(\fIinterp, handle, blockPtr, x, y, width, height,\
|
||||
zoomX, zoomY, subsampleX, subsampleY, compRule\fR)
|
||||
.VE 8.5
|
||||
.sp
|
||||
int
|
||||
\fBTk_PhotoGetImage\fR(\fIhandle, blockPtr\fR)
|
||||
@@ -37,18 +35,14 @@ int
|
||||
void
|
||||
\fBTk_PhotoBlank\fR(\fIhandle\fR)
|
||||
.sp
|
||||
.VS 8.5
|
||||
int
|
||||
\fBTk_PhotoExpand\fR(\fIinterp, handle, width, height\fR)
|
||||
.VE 8.5
|
||||
.sp
|
||||
void
|
||||
\fBTk_PhotoGetSize\fR(\fIhandle, widthPtr, heightPtr\fR)
|
||||
.sp
|
||||
.VS 8.5
|
||||
int
|
||||
\fBTk_PhotoSetSize\fR(\fIinterp. handle, width, height\fR)
|
||||
.VE 8.5
|
||||
.SH ARGUMENTS
|
||||
.AS Tk_PhotoImageBlock window_path
|
||||
.AP Tcl_Interp *interp in
|
||||
@@ -99,13 +93,14 @@ being written to the photo image.
|
||||
Specifies the zoom factor to be applied in the Y direction to pixels
|
||||
being written to the photo image.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_FindPhoto\fR returns an opaque handle that is used to identify a
|
||||
particular photo image to the other procedures. The parameter is the
|
||||
name of the image, that is, the name specified to the \fBimage create
|
||||
photo\fR command, or assigned by that command if no name was specified.
|
||||
If \fIimageName\fR does not exist or is not a photo image,
|
||||
\fBTk_FindPhoto\fR returns NULL.
|
||||
.PP
|
||||
\fBTk_PhotoPutBlock\fR is used to supply blocks of image data to be
|
||||
displayed. The call affects an area of the image of size
|
||||
@@ -128,21 +123,30 @@ typedef struct {
|
||||
int \fIheight\fR;
|
||||
int \fIpitch\fR;
|
||||
int \fIpixelSize\fR;
|
||||
int \fIoffset[4]\fR;
|
||||
} Tk_PhotoImageBlock;
|
||||
int \fIoffset\fR[4];
|
||||
} \fBTk_PhotoImageBlock\fR;
|
||||
.CE
|
||||
The \fIpixelPtr\fR field points to the first pixel, that is, the
|
||||
top-left pixel in the block.
|
||||
The \fIwidth\fR and \fIheight\fR fields specify the dimensions of the
|
||||
block of pixels. The \fIpixelSize\fR field specifies the address
|
||||
difference between two horizontally adjacent pixels. Often it is 3
|
||||
or 4, but it can have any value. The \fIpitch\fR field specifies the
|
||||
difference between two horizontally adjacent pixels. It should be 4 for
|
||||
RGB and 2 for grayscale image data. Other values are possible, if the
|
||||
offsets in the \fIoffset\fR array are adjusted accordingly (e.g. for
|
||||
red, green and blue data stored in different planes). Using such a
|
||||
layout is strongly discouraged, though. Due to a bug, it might not work
|
||||
correctly if an alpha channel is provided. (see the \fBBUGS\fR section
|
||||
below). The \fIpitch\fR field specifies the
|
||||
address difference between two vertically adjacent pixels. The
|
||||
\fIoffset\fR array contains the offsets from the address of a pixel
|
||||
to the addresses of the bytes containing the red, green, blue and alpha
|
||||
(transparency) components. These are normally 0, 1, 2 and 3, but can
|
||||
have other values, e.g., for images that are stored as separate red,
|
||||
green and blue planes.
|
||||
(transparency) components. If the offsets for red, green and blue are
|
||||
equal, the image is interpreted as grayscale. If they differ, RGB data
|
||||
is assumed. Normally the offsets will be 0, 1, 2, 3 for RGB data
|
||||
and 0, 0, 0, 1 for grayscale. It is possible to provide image data
|
||||
without an alpha channel by setting the offset for alpha to a negative
|
||||
value and adjusting the \fIpixelSize\fR field accordingly. This use is
|
||||
discouraged, though (see the \fBBUGS\fR section below).
|
||||
.PP
|
||||
The \fIcompRule\fR parameter to \fBTk_PhotoPutBlock\fR specifies a
|
||||
compositing rule that says what to do with transparent pixels. The
|
||||
@@ -161,12 +165,10 @@ given are replicated (in a tiled fashion) to fill the specified area.
|
||||
These rules operate independently in the horizontal and vertical
|
||||
directions.
|
||||
.PP
|
||||
.VS 8.5
|
||||
\fBTk_PhotoPutBlock\fR normally returns \fBTCL_OK\fR, though if it cannot
|
||||
allocate sufficient memory to hold the resulting image, \fBTCL_ERROR\fR is
|
||||
returned instead and, if the \fIinterp\fR argument is non-NULL, an
|
||||
error message is placed in the interpreter's result.
|
||||
.VE 8.5
|
||||
.PP
|
||||
\fBTk_PhotoPutZoomedBlock\fR works like \fBTk_PhotoPutBlock\fR except that
|
||||
the image can be reduced or enlarged for display. The
|
||||
@@ -190,6 +192,18 @@ in the structure pointed to by the \fIblockPtr\fR parameter with values
|
||||
that describe the address and layout of the image data that the
|
||||
photo image has stored internally. The values are valid
|
||||
until the image is destroyed or its size is changed.
|
||||
.PP
|
||||
It is possible to modify an image by writing directly to the data
|
||||
the \fIpixelPtr\fR field points to. The size of the image cannot be
|
||||
changed this way, though.
|
||||
Also, changes made by writing directly to \fIpixelPtr\fR will not be
|
||||
immediately visible, but only after a call to
|
||||
\fBTk_ImageChanged\fR or after an event that causes the interested
|
||||
widgets to redraw themselves.
|
||||
For these reasons usually it is preferable to make changes to
|
||||
a copy of the image data and write it back with
|
||||
\fBTk_PhotoPutBlock\fR or \fBTk_PhotoPutZoomedBlock\fR.
|
||||
.PP
|
||||
\fBTk_PhotoGetImage\fR returns 1 for compatibility with the
|
||||
corresponding procedure in the old photo widget.
|
||||
.PP
|
||||
@@ -207,12 +221,10 @@ are being supplied in many small blocks, it is more efficient to use
|
||||
allowing the image to expand in many small increments as image blocks
|
||||
are supplied.
|
||||
.PP
|
||||
.VS 8.5
|
||||
\fBTk_PhotoExpand\fR normally returns \fBTCL_OK\fR, though if it cannot
|
||||
allocate sufficient memory to hold the resulting image, \fBTCL_ERROR\fR is
|
||||
returned instead and, if the \fIinterp\fR argument is non-NULL, an
|
||||
error message is placed in the interpreter's result.
|
||||
.VE 8.5
|
||||
.PP
|
||||
\fBTk_PhotoSetSize\fR specifies the size of the image, as if the user
|
||||
had specified the given \fIwidth\fR and \fIheight\fR values to the
|
||||
@@ -222,16 +234,13 @@ or height, but allows the width or height to be changed by subsequent
|
||||
calls to \fBTk_PhotoPutBlock\fR, \fBTk_PhotoPutZoomedBlock\fR or
|
||||
\fBTk_PhotoExpand\fR.
|
||||
.PP
|
||||
.VS 8.5
|
||||
\fBTk_PhotoSetSize\fR normally returns \fBTCL_OK\fR, though if it cannot
|
||||
allocate sufficient memory to hold the resulting image, \fBTCL_ERROR\fR is
|
||||
returned instead and, if the \fIinterp\fR argument is non-NULL, an
|
||||
error message is placed in the interpreter's result.
|
||||
.VE 8.5
|
||||
.PP
|
||||
\fBTk_PhotoGetSize\fR returns the dimensions of the image in
|
||||
*\fIwidthPtr\fR and *\fIheightPtr\fR.
|
||||
|
||||
.SH PORTABILITY
|
||||
.PP
|
||||
In Tk 8.3 and earlier, \fBTk_PhotoPutBlock\fR and
|
||||
@@ -241,7 +250,6 @@ your code, compile it with the flag
|
||||
-DUSE_COMPOSITELESS_PHOTO_PUT_BLOCK. Code linked using Stubs against
|
||||
older versions of Tk will continue to work.
|
||||
.PP
|
||||
.VS 8.5
|
||||
In Tk 8.4, \fBTk_PhotoPutBlock\fR, \fBTk_PhotoPutZoomedBlock\fR,
|
||||
\fBTk_PhotoExpand\fR and \fBTk_PhotoSetSize\fR did not take an
|
||||
\fIinterp\fR argument or return any result code. If insufficient
|
||||
@@ -249,12 +257,27 @@ memory was available for an image, Tk would panic. This behaviour is
|
||||
still supported if you compile your extension with the additional flag
|
||||
-DUSE_PANIC_ON_PHOTO_ALLOC_FAILURE. Code linked using Stubs against
|
||||
older versions of Tk will continue to work.
|
||||
.VE 8.5
|
||||
|
||||
.SH BUGS
|
||||
The \fBTk_PhotoImageBlock\fR structure used to provide image data to
|
||||
\fBTk_PhotoPutBlock\fR promises great flexibility in the layout of the
|
||||
data (e.g. separate planes for the red, green, blue and alpha
|
||||
channels). Unfortunately, the implementation fails to hold this
|
||||
promise. The problem is that the \fIpixelSize\fR field is
|
||||
(incorrectly) used to determine whether the image has an alpha channel.
|
||||
Currently, if the offset for the alpha channel is greater or equal than
|
||||
\fIpixelSize\fR, \fBtk_PhotoPutblock\fR assumes no alpha data is
|
||||
present and makes the image fully opaque. This means that for layouts
|
||||
where the channels are separate (or any other exotic layout where
|
||||
\fIpixelSize\fR has to be smaller than the alpha offset), the alpha
|
||||
channel will not be read correctly. In order to be on the safe side
|
||||
if this issue will be corrected in a future release, it is strongly
|
||||
recommended you always provide alpha data - even if the image has no
|
||||
transparency - and only use the "standard" layout with a
|
||||
\fIpixelSize\fR of 2 for grayscale and 4 for RGB data with
|
||||
\fIoffset\fRs of 0, 0, 0, 1 or 0, 1, 2, 3 respectively.
|
||||
.SH CREDITS
|
||||
.PP
|
||||
The code for the photo image type was developed by Paul Mackerras,
|
||||
based on his earlier photo widget code.
|
||||
|
||||
.SH KEYWORDS
|
||||
photo, image
|
||||
|
||||
15
doc/FontId.3
15
doc/FontId.3
@@ -3,12 +3,12 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_FontId 3 8.0 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
.SH NAME
|
||||
Tk_FontId, Tk_GetFontMetrics, Tk_PostscriptFontName \- accessor functions for
|
||||
Tk_FontId, Tk_GetFontMetrics, Tk_PostscriptFontName \- accessor functions for
|
||||
fonts
|
||||
.SH SYNOPSIS
|
||||
.nf
|
||||
@@ -37,7 +37,7 @@ Postscript font that corresponds to \fItkfont\fR will be appended.
|
||||
.PP
|
||||
Given a \fItkfont\fR, \fBTk_FontId\fR returns the token that should be
|
||||
selected into an XGCValues structure in order to construct a graphics
|
||||
context that can be used to draw text in the specified font.
|
||||
context that can be used to draw text in the specified font.
|
||||
.PP
|
||||
\fBTk_GetFontMetrics\fR computes the ascent, descent, and linespace of the
|
||||
\fItkfont\fR in pixels and stores those values in the structure pointer to by
|
||||
@@ -45,7 +45,7 @@ context that can be used to draw text in the specified font.
|
||||
multiple lines of text, to align the baselines of text in different
|
||||
fonts, and to vertically align text in a given region. See the
|
||||
documentation for the \fBfont\fR command for definitions of the terms
|
||||
ascent, descent, and linespace, used in font metrics.
|
||||
ascent, descent, and linespace, used in font metrics.
|
||||
.PP
|
||||
\fBTk_PostscriptFontName\fR maps a \fItkfont\fR to the corresponding
|
||||
Postscript font name that should be used when printing. The return value
|
||||
@@ -56,15 +56,16 @@ appended to \fIdsPtr\fR. \fIDsPtr\fR must refer to an initialized
|
||||
Postscript printer, the
|
||||
following screen font families should print correctly:
|
||||
.IP
|
||||
\fBAvant Garde\fR, \fBArial\fR, \fBBookman\fR, \fBCourier\fR,
|
||||
\fBAvant Garde\fR, \fBArial\fR, \fBBookman\fR, \fBCourier\fR,
|
||||
\fBCourier New\fR, \fBGeneva\fR, \fBHelvetica\fR, \fBMonaco\fR,
|
||||
\fBNew Century Schoolbook\fR, \fBNew York\fR, \fBPalatino\fR, \fBSymbol\fR,
|
||||
\fBTimes\fR, \fBTimes New Roman\fR, \fBZapf Chancery\fR, and
|
||||
\fBTimes\fR, \fBTimes New Roman\fR, \fBZapf Chancery\fR, and
|
||||
\fBZapf Dingbats\fR.
|
||||
.PP
|
||||
Any other font families may not print correctly because the computed
|
||||
Postscript font name may be incorrect or not exist on the printer.
|
||||
.SH "DATA STRUCTURES"
|
||||
.PP
|
||||
The \fBTk_FontMetrics\fR data structure is used by \fBTk_GetFontMetrics\fR to
|
||||
return information about a font and is defined as follows:
|
||||
.CS
|
||||
@@ -72,7 +73,7 @@ typedef struct Tk_FontMetrics {
|
||||
int \fIascent\fR;
|
||||
int \fIdescent\fR;
|
||||
int \fIlinespace\fR;
|
||||
} Tk_FontMetrics;
|
||||
} \fBTk_FontMetrics\fR;
|
||||
.CE
|
||||
.PP
|
||||
The \fIascent\fR field is the amount in pixels that the tallest
|
||||
|
||||
@@ -44,7 +44,6 @@ Space to leave for top side of internal border for \fItkwin\fR, in pixel units.
|
||||
.AP int bottom in
|
||||
Space to leave for bottom side of internal border for \fItkwin\fR, in pixel units.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GeometryRequest\fR is called by widget code to indicate its
|
||||
@@ -89,6 +88,5 @@ The information specified in calls to \fBTk_GeometryRequest\fR,
|
||||
\fBTk_InternalBorderRight\fR, \fBTk_InternalBorderTop\fR and
|
||||
\fBTk_InternalBorderBottom\fR.
|
||||
See the \fBTk_WindowId\fR manual entry for details.
|
||||
|
||||
.SH KEYWORDS
|
||||
geometry, request
|
||||
|
||||
@@ -28,17 +28,20 @@ const char *
|
||||
Interpreter to use for error reporting, or NULL.
|
||||
.AP Tcl_Obj *objPtr in/out
|
||||
String value contains name of anchor point:
|
||||
.QW n ,
|
||||
.QW ne ,
|
||||
.QW e ,
|
||||
.QW se ,
|
||||
.QW s ,
|
||||
.QW sw ,
|
||||
.QW w ,
|
||||
.QW nw ,
|
||||
.QW \fBn\fR ,
|
||||
.QW \fBne\fR ,
|
||||
.QW \fBe\fR ,
|
||||
.QW \fBse\fR ,
|
||||
.QW \fBs\fR ,
|
||||
.QW \fBsw\fR ,
|
||||
.QW \fBw\fR ,
|
||||
.QW \fBnw\fR ,
|
||||
or
|
||||
.QW center ;
|
||||
internal rep will be modified to cache corresponding Tk_Anchor.
|
||||
.QW \fBcenter\fR ;
|
||||
internal rep will be modified to cache corresponding Tk_Anchor. In the
|
||||
case of
|
||||
.QW \fBcenter\fR
|
||||
on input, a non-empty abbreviation of it may also be used on input.
|
||||
.AP "const char" *string in
|
||||
Same as \fIobjPtr\fR except description of anchor point is passed as
|
||||
a string.
|
||||
|
||||
@@ -49,7 +49,7 @@ Same as \fIobjPtr\fR except description of bitmap is passed as a string and
|
||||
resulting Pixmap is not cached.
|
||||
.AP "const char" *name in
|
||||
Name for new bitmap to be defined.
|
||||
.AP "const char" *source in
|
||||
.AP "const void" *source in
|
||||
Data for bitmap, in standard bitmap format.
|
||||
Must be stored in static memory whose value will never change.
|
||||
.AP "int" width in
|
||||
@@ -66,7 +66,6 @@ Display for which \fIbitmap\fR was allocated.
|
||||
Identifier for a bitmap allocated by \fBTk_AllocBitmapFromObj\fR or
|
||||
\fBTk_GetBitmap\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures manage a collection of bitmaps (one-plane pixmaps)
|
||||
@@ -82,7 +81,7 @@ of the following forms:
|
||||
.TP 20
|
||||
\fB@\fIfileName\fR
|
||||
\fIFileName\fR must be the name of a file containing a bitmap
|
||||
description in the standard X11 or X10 format.
|
||||
description in the standard X11 format.
|
||||
.TP 20
|
||||
\fIname\fR
|
||||
\fIName\fR must be the name of a bitmap defined previously with
|
||||
@@ -210,7 +209,7 @@ describe the bitmap.
|
||||
\fBTk_DefineBitmap\fR normally returns \fBTCL_OK\fR; if an error occurs
|
||||
(e.g. a bitmap named \fInameId\fR has already been defined) then
|
||||
\fBTCL_ERROR\fR is returned and an error message is left in
|
||||
\fIinterp->result\fR.
|
||||
interpreter \fIinterp\fR's result.
|
||||
Note: \fBTk_DefineBitmap\fR expects the memory pointed to by
|
||||
\fIsource\fR to be static: \fBTk_DefineBitmap\fR does not make
|
||||
a private copy of this memory, but uses the bytes pointed to
|
||||
@@ -282,8 +281,8 @@ with its Pixmap token.
|
||||
There should be exactly one call to \fBTk_FreeBitmapFromObj\fR
|
||||
or \fBTk_FreeBitmap\fR for each call to \fBTk_AllocBitmapFromObj\fR or
|
||||
\fBTk_GetBitmap\fR.
|
||||
|
||||
.SH BUGS
|
||||
.PP
|
||||
In determining whether an existing bitmap can be used to satisfy
|
||||
a new request, \fBTk_AllocBitmapFromObj\fR and \fBTk_GetBitmap\fR
|
||||
consider only the immediate value of the string description. For
|
||||
@@ -293,6 +292,5 @@ bitmap created from the same file name: it will not check to
|
||||
see whether the file itself has changed, or whether the current
|
||||
directory has changed, thereby causing the name to refer to
|
||||
a different file.
|
||||
|
||||
.SH KEYWORDS
|
||||
bitmap, pixmap
|
||||
|
||||
@@ -24,18 +24,18 @@ const char *
|
||||
.AP Tcl_Interp *interp in
|
||||
Interpreter to use for error reporting.
|
||||
.AP "const char" *string in
|
||||
String containing name of cap style: one of
|
||||
.QW butt ,
|
||||
.QW projecting ,
|
||||
String containing name of cap style \- one of
|
||||
.QW \fBbutt\fR ,
|
||||
.QW \fBprojecting\fR ,
|
||||
or
|
||||
.QW round .
|
||||
.QW \fBround\fR
|
||||
\- or a unique abbreviation of one.
|
||||
.AP int *capPtr out
|
||||
Pointer to location in which to store X cap style corresponding to
|
||||
\fIstring\fR.
|
||||
.AP int cap in
|
||||
Cap style: one of \fBCapButt\fR, \fBCapProjecting\fR, or \fBCapRound\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GetCapStyle\fR places in \fI*capPtr\fR the X cap style
|
||||
@@ -51,7 +51,7 @@ Under normal circumstances the return value is \fBTCL_OK\fR and
|
||||
\fIinterp\fR is unused.
|
||||
If \fIstring\fR does not contain a valid cap style
|
||||
or an abbreviation of one of these names, then an error message is
|
||||
stored in \fIinterp->result\fR, \fBTCL_ERROR\fR is returned, and
|
||||
stored in interpreter \fIinterp\fR's result, \fBTCL_ERROR\fR is returned, and
|
||||
\fI*capPtr\fR is unmodified.
|
||||
.PP
|
||||
\fBTk_NameOfCapStyle\fR is the logical inverse of \fBTk_GetCapStyle\fR.
|
||||
@@ -60,6 +60,5 @@ statically-allocated string corresponding to \fIcap\fR.
|
||||
If \fIcap\fR is not a legal cap style, then
|
||||
.QW "unknown cap style"
|
||||
is returned.
|
||||
|
||||
.SH KEYWORDS
|
||||
butt, cap style, projecting, round
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_AllocColorFromObj 3 8.1 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -58,7 +58,6 @@ call to \fBTk_AllocColorFromObj\fR, \fBTk_GetColor\fR or
|
||||
Drawable in which the result graphics context will be used. Must have
|
||||
same screen and depth as the window for which the color was allocated.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures manage the colors being used by a Tk application.
|
||||
@@ -68,8 +67,8 @@ colormap space is exhausted.
|
||||
.PP
|
||||
Given a textual description of a color, \fBTk_AllocColorFromObj\fR
|
||||
locates a pixel value that may be used to render the color
|
||||
in a particular window. The desired color is specified with an
|
||||
object whose string value must have one of the following forms:
|
||||
in a particular window. The desired color is specified with a
|
||||
value whose string value must have one of the following forms:
|
||||
.TP 20
|
||||
\fIcolorname\fR
|
||||
Any of the valid textual names for a color defined in the
|
||||
@@ -107,7 +106,7 @@ such as \fBTk_AllocColorFromObj\fR and \fBTk_GetColorFromObj\fR.
|
||||
.PP
|
||||
\fBTk_GetColor\fR is identical to \fBTk_AllocColorFromObj\fR except
|
||||
that the description of the color is specified with a string instead
|
||||
of an object. This prevents \fBTk_GetColor\fR from caching the
|
||||
of a value. This prevents \fBTk_GetColor\fR from caching the
|
||||
return value, so \fBTk_GetColor\fR is less efficient than
|
||||
\fBTk_AllocColorFromObj\fR.
|
||||
.PP
|
||||
@@ -128,7 +127,7 @@ This package maintains a database
|
||||
of all the colors currently in use.
|
||||
If the same color is requested multiple times from
|
||||
\fBTk_GetColor\fR or \fBTk_AllocColorFromObj\fR (e.g. by different
|
||||
windows), or if the
|
||||
windows), or if the
|
||||
same intensities are requested multiple times from
|
||||
\fBTk_GetColorByValue\fR, then existing pixel values will
|
||||
be re-used. Re-using an existing pixel avoids any interaction
|
||||
@@ -174,4 +173,4 @@ There should be exactly one call to \fBTk_FreeColorFromObj\fR
|
||||
or \fBTk_FreeColor\fR for each call to \fBTk_AllocColorFromObj\fR,
|
||||
\fBTk_GetColor\fR, or \fBTk_GetColorByValue\fR.
|
||||
.SH KEYWORDS
|
||||
color, intensity, object, pixel value
|
||||
color, intensity, value, pixel value
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_AllocCursorFromObj 3 8.1 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -67,7 +67,6 @@ Opaque Tk identifier for cursor. If passed to \fBTk_FreeCursor\fR, must
|
||||
have been returned by some previous call to \fBTk_GetCursor\fR or
|
||||
\fBTk_GetCursorFromData\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures manage a collection of cursors
|
||||
@@ -118,8 +117,8 @@ in preference to black and white cursors.
|
||||
\fB@\fIsourceName\0maskName\0fgColor\0bgColor\fR
|
||||
In this form, \fIsourceName\fR and \fImaskName\fR are the names of
|
||||
files describing cursors for the cursor's source bits and mask.
|
||||
Each file must be in standard X11 or X10 cursor format.
|
||||
\fIFgColor\fR and \fIbgColor\fR
|
||||
Each file must be in standard X11 cursor format.
|
||||
\fIFgColor\fR and \fIbgColor\fR
|
||||
indicate the colors to use for the
|
||||
cursor, in any of the forms acceptable to \fBTk_GetColor\fR. This
|
||||
form of the command will not work on Macintosh or Windows computers.
|
||||
@@ -213,8 +212,8 @@ with its Tk_Cursor token.
|
||||
There should be exactly one call to \fBTk_FreeCursor\fR for
|
||||
each call to \fBTk_AllocCursorFromObj\fR, \fBTk_GetCursor\fR,
|
||||
or \fBTk_GetCursorFromData\fR.
|
||||
|
||||
.SH BUGS
|
||||
.PP
|
||||
In determining whether an existing cursor can be used to satisfy
|
||||
a new request, \fBTk_AllocCursorFromObj\fR, \fBTk_GetCursor\fR,
|
||||
and \fBTk_GetCursorFromData\fR
|
||||
@@ -228,6 +227,5 @@ a different file. Similarly, \fBTk_GetCursorFromData\fR assumes
|
||||
that if the same \fIsource\fR pointer is used in two different calls,
|
||||
then the pointers refer to the same data; it does not check to
|
||||
see if the actual data values have changed.
|
||||
|
||||
.SH KEYWORDS
|
||||
cursor
|
||||
|
||||
@@ -13,28 +13,30 @@ Tk_GetDash \- convert from string to valid dash structure.
|
||||
.SH SYNOPSIS
|
||||
.nf
|
||||
\fB#include <tk.h>\fR
|
||||
.sp
|
||||
|
||||
int
|
||||
\fBTk_GetDash\fR(\fIinterp, string, dashPtr\fR)
|
||||
.fi
|
||||
.SH ARGUMENTS
|
||||
.AS Tk_Dash *dashPtr
|
||||
.AP Tcl_Interp *interp in
|
||||
Interpreter to use for error reporting.
|
||||
.AP "const char *" string in
|
||||
.AP "const char" *string in
|
||||
Textual value to be converted.
|
||||
.AP Tk_Dash *dashPtr out
|
||||
Points to place to store the dash pattern
|
||||
value converted from \fIstring\fR.
|
||||
value converted from \fIstring\fR. Must not be NULL.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedure parses the string and fills in the result in the
|
||||
Tk_Dash structure. The string can be a list of integers or a
|
||||
character string containing only
|
||||
.QW \fB.,\-_\fR
|
||||
or spaces. If all
|
||||
goes well, \fBTCL_OK\fR is returned. If \fIstring\fR does not have the
|
||||
.QW \fB.,-_\fR
|
||||
and spaces. If all
|
||||
goes well, \fBTCL_OK\fR is returned and a dash descriptor is stored
|
||||
in the variable pointed to by \fIdashPtr\fR.
|
||||
If \fIstring\fR does not have the
|
||||
proper syntax then \fBTCL_ERROR\fR is returned, an error message is left
|
||||
in the interpreter's result, and nothing is stored at *\fIdashPtr\fR.
|
||||
.PP
|
||||
@@ -46,33 +48,35 @@ color. The other segments are drawn transparent.
|
||||
.PP
|
||||
The second possible syntax is a character list containing only
|
||||
5 possible characters
|
||||
.QW "\fB.,\-_ \fR" .
|
||||
.QW "\fB.,-_ \fR" .
|
||||
The space can be used
|
||||
to enlarge the space between other line elements, and can not
|
||||
occur as the first position in the string. Some examples:
|
||||
occur in the first position of the string. Some examples:
|
||||
.PP
|
||||
.CS
|
||||
\-dash . = \-dash {2 4}
|
||||
\-dash \- = \-dash {6 4}
|
||||
\-dash \-. = \-dash {6 4 2 4}
|
||||
\-dash \-.. = \-dash {6 4 2 4 2 4}
|
||||
\-dash - = \-dash {6 4}
|
||||
\-dash -. = \-dash {6 4 2 4}
|
||||
\-dash -.. = \-dash {6 4 2 4 2 4}
|
||||
\-dash {. } = \-dash {2 8}
|
||||
\-dash , = \-dash {4 4}
|
||||
.CE
|
||||
.PP
|
||||
The main difference of this syntax with the previous is that it
|
||||
The main difference between this syntax and the numeric is that it
|
||||
is shape-conserving. This means that all values in the dash
|
||||
list will be multiplied by the line width before display. This
|
||||
assures that
|
||||
ensures that
|
||||
.QW .
|
||||
will always be displayed as a dot and
|
||||
.QW \-
|
||||
.QW -
|
||||
always as a dash regardless of the line width.
|
||||
.PP
|
||||
On systems where only a limited set of dash patterns, the dash
|
||||
pattern will be displayed as the most close dash pattern that
|
||||
is available. For example, on Windows only the first 4 of the
|
||||
above examples are available. The last 2 examples will be
|
||||
displayed identically as the first one.
|
||||
|
||||
above examples are available; the last 2 examples will be
|
||||
displayed identically to the first one.
|
||||
.SH "SEE ALSO"
|
||||
canvas(n), Tk_CreateItemType(3)
|
||||
.SH KEYWORDS
|
||||
dash, conversion
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_AllocFontFromObj 3 8.1 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -14,24 +14,23 @@ Tk_AllocFontFromObj, Tk_GetFont, Tk_GetFontFromObj, Tk_NameOfFont, Tk_FreeFontFr
|
||||
.nf
|
||||
\fB#include <tk.h>\fR
|
||||
.sp
|
||||
Tk_Font
|
||||
Tk_Font
|
||||
\fBTk_AllocFontFromObj(\fIinterp, tkwin, objPtr\fB)\fR
|
||||
.sp
|
||||
Tk_Font
|
||||
\fBTk_GetFont(\fIinterp, tkwin, string\fB)\fR
|
||||
Tk_Font
|
||||
\fBTk_GetFont(\fIinterp, tkwin, string\fB)\fR
|
||||
.sp
|
||||
Tk_Font
|
||||
Tk_Font
|
||||
\fBTk_GetFontFromObj(\fItkwin, objPtr\fB)\fR
|
||||
.sp
|
||||
const char *
|
||||
\fBTk_NameOfFont(\fItkfont\fB)\fR
|
||||
.sp
|
||||
Tk_Font
|
||||
Tk_Font
|
||||
\fBTk_FreeFontFromObj(\fItkwin, objPtr\fB)\fR
|
||||
.sp
|
||||
void
|
||||
\fBTk_FreeFont(\fItkfont\fB)\fR
|
||||
|
||||
.SH ARGUMENTS
|
||||
.AS "const char" *tkfont
|
||||
.AP "Tcl_Interp" *interp in
|
||||
@@ -56,7 +55,7 @@ returns a token that represents the font. The return value can be used
|
||||
in subsequent calls to procedures such as \fBTk_GetFontMetrics\fR,
|
||||
\fBTk_MeasureChars\fR, and \fBTk_FreeFont\fR. The Tk_Font token
|
||||
will remain valid until
|
||||
\fBTk_FreeFontFromObj\fR or \fBTk_FreeFont\fR is called to release it.
|
||||
\fBTk_FreeFontFromObj\fR or \fBTk_FreeFont\fR is called to release it.
|
||||
\fIObjPtr\fR can contain either a symbolic name or a font description; see
|
||||
the documentation for the \fBfont\fR command for a description of the
|
||||
valid formats. If \fBTk_AllocFontFromObj\fR is unsuccessful (because,
|
||||
@@ -105,7 +104,6 @@ with the same information used to create it; for
|
||||
with its Tk_Font token. There should be
|
||||
exactly one call to \fBTk_FreeFontFromObj\fR or \fBTk_FreeFont\fR
|
||||
for each call to \fBTk_AllocFontFromObj\fR or \fBTk_GetFont\fR.
|
||||
|
||||
.SH "SEE ALSO"
|
||||
Tk_FontId(3)
|
||||
.SH KEYWORDS
|
||||
|
||||
@@ -34,7 +34,6 @@ Display for which \fIgc\fR was allocated.
|
||||
X identifier for graphics context that is no longer needed.
|
||||
Must have been allocated by \fBTk_GetGC\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GetGC\fR and \fBTk_FreeGC\fR manage a collection of graphics contexts
|
||||
@@ -67,6 +66,5 @@ each call to \fBTk_GetGC\fR.
|
||||
When a graphics context is no longer in use anywhere (i.e. it has
|
||||
been freed as many times as it has been gotten) \fBTk_FreeGC\fR
|
||||
will release it to the X server and delete it from the database.
|
||||
|
||||
.SH KEYWORDS
|
||||
graphics context
|
||||
|
||||
@@ -32,6 +32,5 @@ window given by \fIwindow\fR.
|
||||
\fBTk_AttachHWND\fR binds the Windows HWND identifier to the
|
||||
specified Tk_Window given by \fItkwin\fR. It returns an X Windows
|
||||
window that encapsulates the HWND.
|
||||
|
||||
.SH KEYWORDS
|
||||
identifier, window
|
||||
|
||||
@@ -63,7 +63,6 @@ Store width of \fIimage\fR (in pixels) here.
|
||||
.AP "int" heightPtr out
|
||||
Store height of \fIimage\fR (in pixels) here.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures are invoked by widgets that wish to display images.
|
||||
@@ -74,7 +73,7 @@ identifies the window where the image will be displayed.
|
||||
\fBTk_GetImage\fR looks up the image in the table of existing
|
||||
images and returns a token for a new instance of the image.
|
||||
If the image does not exist then \fBTk_GetImage\fR returns NULL
|
||||
and leaves an error message in \fIinterp->result\fR.
|
||||
and leaves an error message in interpreter \fIinterp\fR's result.
|
||||
.PP
|
||||
When a widget wishes to actually display an image it must
|
||||
call \fBTk_RedrawImage\fR, identifying the image (\fIimage\fR),
|
||||
@@ -106,14 +105,14 @@ The \fIchangeProc\fR and \fIclientData\fR arguments to
|
||||
\fIchangeProc\fR will be called by Tk whenever a change occurs
|
||||
in the image; it must match the following prototype:
|
||||
.CS
|
||||
typedef void Tk_ImageChangedProc(
|
||||
ClientData \fIclientData\fR,
|
||||
int \fIx\fR,
|
||||
int \fIy\fR,
|
||||
int \fIwidth\fR,
|
||||
int \fIheight\fR,
|
||||
int \fIimageWidth\fR,
|
||||
int \fIimageHeight\fR);
|
||||
typedef void \fBTk_ImageChangedProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
int \fIx\fR,
|
||||
int \fIy\fR,
|
||||
int \fIwidth\fR,
|
||||
int \fIheight\fR,
|
||||
int \fIimageWidth\fR,
|
||||
int \fIimageHeight\fR);
|
||||
.CE
|
||||
The \fIclientData\fR argument to \fIchangeProc\fR is the same as the
|
||||
\fIclientData\fR argument to \fBTk_GetImage\fR.
|
||||
@@ -125,9 +124,7 @@ they are specified in pixels measured from the upper-left
|
||||
corner of the image.
|
||||
The arguments \fIimageWidth\fR and \fIimageHeight\fR give
|
||||
the image's (new) size.
|
||||
|
||||
.SH "SEE ALSO"
|
||||
Tk_CreateImageType
|
||||
|
||||
.SH KEYWORDS
|
||||
images, redisplay
|
||||
|
||||
@@ -24,18 +24,18 @@ const char *
|
||||
.AP Tcl_Interp *interp in
|
||||
Interpreter to use for error reporting.
|
||||
.AP "const char" *string in
|
||||
String containing name of join style: one of
|
||||
.QW bevel ,
|
||||
.QW miter ,
|
||||
String containing name of join style \- one of
|
||||
.QW \fBbevel\fR ,
|
||||
.QW \fBmiter\fR ,
|
||||
or
|
||||
.QW round .
|
||||
.QW \fBround\fR
|
||||
\- or a unique abbreviation of one.
|
||||
.AP int *joinPtr out
|
||||
Pointer to location in which to store X join style corresponding to
|
||||
\fIstring\fR.
|
||||
.AP int join in
|
||||
Join style: one of \fBJoinBevel\fR, \fBJoinMiter\fR, \fBJoinRound\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GetJoinStyle\fR places in \fI*joinPtr\fR the X join style
|
||||
@@ -50,7 +50,7 @@ Under normal circumstances the return value is \fBTCL_OK\fR and
|
||||
\fIinterp\fR is unused.
|
||||
If \fIstring\fR does not contain a valid join style
|
||||
or an abbreviation of one of these names, then an error message is
|
||||
stored in \fIinterp->result\fR, \fBTCL_ERROR\fR is returned, and
|
||||
stored in interpreter \fIinterp\fR's result, \fBTCL_ERROR\fR is returned, and
|
||||
\fI*joinPtr\fR is unmodified.
|
||||
.PP
|
||||
\fBTk_NameOfJoinStyle\fR is the logical inverse of \fBTk_GetJoinStyle\fR.
|
||||
@@ -59,6 +59,5 @@ statically-allocated string corresponding to \fIjoin\fR.
|
||||
If \fIjoin\fR is not a legal join style, then
|
||||
.QW "unknown join style"
|
||||
is returned.
|
||||
|
||||
.SH KEYWORDS
|
||||
bevel, join style, miter, round
|
||||
|
||||
@@ -27,11 +27,12 @@ const char *
|
||||
.AP Tcl_Interp *interp in
|
||||
Interpreter to use for error reporting, or NULL.
|
||||
.AP Tcl_Obj *objPtr in/out
|
||||
String value contains name of justification style, one of
|
||||
.QW left ,
|
||||
.QW right ,
|
||||
String value contains name of justification style \- one of
|
||||
.QW \fBleft\fR ,
|
||||
.QW \fBright\fR ,
|
||||
or
|
||||
.QW center .
|
||||
.QW \fBcenter\fR
|
||||
\- or a unique abbreviation of one.
|
||||
The internal rep will be modified to cache corresponding justify value.
|
||||
.AP "const char" *string in
|
||||
Same as \fIobjPtr\fR except description of justification style is passed as
|
||||
@@ -82,6 +83,5 @@ corresponding to \fIjustify\fR.
|
||||
If \fIjustify\fR is not a legal justify value, then
|
||||
.QW "unknown justification style"
|
||||
is returned.
|
||||
|
||||
.SH KEYWORDS
|
||||
center, fill, justification, string
|
||||
|
||||
@@ -26,7 +26,6 @@ Name of desired option.
|
||||
Class of desired option. Null means there is no class for
|
||||
this option; do lookup based on name only.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
This procedure is invoked to retrieve an option from the database
|
||||
@@ -39,6 +38,5 @@ is returned. If no option matches, then NULL is returned.
|
||||
\fBTk_GetOption\fR caches options related to \fItkwin\fR so that
|
||||
successive calls for the same \fItkwin\fR will execute much more
|
||||
quickly than successive calls for different windows.
|
||||
|
||||
.SH KEYWORDS
|
||||
class, name, option, retrieve
|
||||
|
||||
@@ -43,7 +43,6 @@ Pointer to location in which to store converted distance in pixels.
|
||||
.AP double *doublePtr out
|
||||
Pointer to location in which to store converted distance in millimeters.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures take as argument a specification of distance on
|
||||
@@ -85,13 +84,12 @@ value in \fIobjPtr\fR, which speeds up future calls to
|
||||
\fBTk_GetPixels\fR is identical to \fBTk_GetPixelsFromObj\fR except
|
||||
that the screen distance is specified with a string instead
|
||||
of an object. This prevents \fBTk_GetPixels\fR from caching the
|
||||
return value, so \fBTk_GetAnchor\fR is less efficient than
|
||||
return value, so \fBTk_GetPixels\fR is less efficient than
|
||||
\fBTk_GetPixelsFromObj\fR.
|
||||
.PP
|
||||
\fBTk_GetMMFromObj\fR and \fBTk_GetScreenMM\fR are similar to
|
||||
\fBTk_GetPixelsFromObj\fR and \fBTk_GetPixels\fR (respectively) except
|
||||
that they convert the screen distance to millimeters and
|
||||
store a double-precision floating-point result at \fI*doublePtr\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
centimeters, convert, inches, millimeters, pixels, points, screen units
|
||||
|
||||
@@ -33,7 +33,6 @@ Number of bits per pixel in pixmap.
|
||||
.AP Pixmap pixmap in
|
||||
Pixmap to destroy.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures are identical to the Xlib procedures \fBXCreatePixmap\fR
|
||||
@@ -49,6 +48,5 @@ with dimensions given by \fIwidth\fR, \fIheight\fR, and \fIdepth\fR,
|
||||
and returns its identifier.
|
||||
\fBTk_FreePixmap\fR destroys the pixmap given by \fIpixmap\fR and makes
|
||||
its resource identifier available for reuse.
|
||||
|
||||
.SH KEYWORDS
|
||||
pixmap, resource identifier
|
||||
|
||||
@@ -28,13 +28,14 @@ const char *
|
||||
Interpreter to use for error reporting.
|
||||
.AP Tcl_Obj *objPtr in/out
|
||||
String value contains name of relief, one of
|
||||
.QW flat ,
|
||||
.QW groove ,
|
||||
.QW raised ,
|
||||
.QW ridge ,
|
||||
.QW solid ,
|
||||
.QW \fBflat\fR ,
|
||||
.QW \fBgroove\fR ,
|
||||
.QW \fBraised\fR ,
|
||||
.QW \fBridge\fR ,
|
||||
.QW \fBsolid\fR ,
|
||||
or
|
||||
.QW sunken ;
|
||||
.QW \fBsunken\fR
|
||||
(or any unique abbreviation thereof on input);
|
||||
the internal rep will be modified to cache corresponding relief value.
|
||||
.AP char *string in
|
||||
Same as \fIobjPtr\fR except description of relief is passed as
|
||||
|
||||
@@ -9,46 +9,45 @@
|
||||
.so man.macros
|
||||
.BS
|
||||
.SH NAME
|
||||
Tk_GetScrollInfo, Tk_GetScrollInfoObj \- parse arguments for scrolling commands
|
||||
Tk_GetScrollInfoObj, Tk_GetScrollInfo \- parse arguments for scrolling commands
|
||||
.SH SYNOPSIS
|
||||
.nf
|
||||
\fB#include <tk.h>\fR
|
||||
.sp
|
||||
int
|
||||
\fBTk_GetScrollInfo(\fIinterp, argc, argv, dblPtr, intPtr\fB)\fR
|
||||
\fBTk_GetScrollInfoObj(\fIinterp, objc, objv, dblPtr, intPtr\fB)\fR
|
||||
.sp
|
||||
int
|
||||
\fBTk_GetScrollInfoObj(\fIinterp, objc, objv, dblPtr, intPtr\fB)\fR
|
||||
\fBTk_GetScrollInfo(\fIinterp, argc, argv, dblPtr, intPtr\fB)\fR
|
||||
.SH ARGUMENTS
|
||||
.AS "Tcl_Interp" *dblPtr
|
||||
.AS "Tcl_Interp" *fractionPtr
|
||||
.AP Tcl_Interp *interp in
|
||||
Interpreter to use for error reporting.
|
||||
.AP int argc in
|
||||
Number of strings in \fIargv\fR array.
|
||||
.AP "const char" *argv[] in
|
||||
Argument strings. These represent the entire widget command, of
|
||||
which the first word is typically the widget name and the second
|
||||
word is typically \fBxview\fR or \fByview\fR.
|
||||
.AP int objc in
|
||||
Number of Tcl_Obj's in \fIobjv\fR array.
|
||||
.AP "Tcl_Obj *const" objv[] in
|
||||
Argument objects. These represent the entire widget command, of
|
||||
which the first word is typically the widget name and the second
|
||||
word is typically \fBxview\fR or \fByview\fR.
|
||||
.AP double *dblPtr out
|
||||
.AP int argc in
|
||||
Number of strings in \fIargv\fR array.
|
||||
.AP "const char" *argv[] in
|
||||
Argument strings. These represent the entire widget command, of
|
||||
which the first word is typically the widget name and the second
|
||||
word is typically \fBxview\fR or \fByview\fR.
|
||||
.AP double *fractionPtr out
|
||||
Filled in with fraction from \fBmoveto\fR option, if any.
|
||||
.AP int *intPtr out
|
||||
.AP int *stepsPtr out
|
||||
Filled in with line or page count from \fBscroll\fR option, if any.
|
||||
The value may be negative.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GetScrollInfo\fR parses the arguments expected by widget
|
||||
\fBTk_GetScrollInfoObj\fR parses the arguments expected by widget
|
||||
scrolling commands such as \fBxview\fR and \fByview\fR.
|
||||
It receives the entire list of words that make up a widget command
|
||||
and parses the words starting with \fIargv\fR[2].
|
||||
The words starting with \fIargv\fR[2] must have one of the following forms:
|
||||
and parses the words starting with \fIobjv\fR[2].
|
||||
The words starting with \fIobjv\fR[2] must have one of the following forms:
|
||||
.CS
|
||||
\fBmoveto \fIfraction\fR
|
||||
\fBscroll \fInumber\fB units\fR
|
||||
@@ -57,20 +56,20 @@ The words starting with \fIargv\fR[2] must have one of the following forms:
|
||||
.LP
|
||||
Any of the \fBmoveto\fR, \fBscroll\fR, \fBunits\fR, and \fBpages\fR
|
||||
keywords may be abbreviated.
|
||||
If \fIargv\fR has the \fBmoveto\fR form, \fBTK_SCROLL_MOVETO\fR
|
||||
is returned as result and \fI*dblPtr\fR is filled in with the
|
||||
If \fIobjv\fR has the \fBmoveto\fR form, \fBTK_SCROLL_MOVETO\fR
|
||||
is returned as result and \fI*fractionPtr\fR is filled in with the
|
||||
\fIfraction\fR argument to the command, which must be a proper real
|
||||
value.
|
||||
If \fIargv\fR has the \fBscroll\fR form, \fBTK_SCROLL_UNITS\fR
|
||||
or \fBTK_SCROLL_PAGES\fR is returned and \fI*intPtr\fR is filled
|
||||
If \fIobjv\fR has the \fBscroll\fR form, \fBTK_SCROLL_UNITS\fR
|
||||
or \fBTK_SCROLL_PAGES\fR is returned and \fI*stepsPtr\fR is filled
|
||||
in with the \fInumber\fR value, which must be a proper integer.
|
||||
If an error occurs in parsing the arguments, \fBTK_SCROLL_ERROR\fR
|
||||
is returned and an error message is left in \fIinterp->result\fR.
|
||||
is returned and an error message is left in interpreter
|
||||
\fIinterp\fR's result.
|
||||
.PP
|
||||
\fBTk_GetScrollInfoObj\fR is identical in function to
|
||||
\fBTk_GetScrollInfo\fR. However, \fBTk_GetScrollInfoObj\fR accepts
|
||||
Tcl_Obj style arguments, making it more appropriate for use with new
|
||||
development.
|
||||
|
||||
\fBTk_GetScrollInfo\fR is identical in function to
|
||||
\fBTk_GetScrollInfoObj\fR. However, \fBTk_GetScrollInfo\fR accepts
|
||||
string arguments, making it more appropriate for use with legacy
|
||||
widgets.
|
||||
.SH KEYWORDS
|
||||
parse, scrollbar, scrolling command, xview, yview
|
||||
|
||||
@@ -33,7 +33,6 @@ are retrieved.
|
||||
.AP ClientData clientData in
|
||||
Arbitrary one-word value to pass to \fIproc\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GetSelection\fR retrieves the selection specified by the atom
|
||||
@@ -42,13 +41,15 @@ selection may actually be retrieved in several pieces; as each piece
|
||||
is retrieved, \fIproc\fR is called to process the piece. \fIProc\fR
|
||||
should have arguments and result that match the type
|
||||
\fBTk_GetSelProc\fR:
|
||||
.PP
|
||||
.CS
|
||||
typedef int Tk_GetSelProc(
|
||||
ClientData \fIclientData\fR,
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
char *\fIportion\fR);
|
||||
typedef int \fBTk_GetSelProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
Tcl_Interp *\fIinterp\fR,
|
||||
char *\fIportion\fR);
|
||||
.CE
|
||||
The \fIclientData\fR and \fIinterp\fR parameters to \fIproc\fR
|
||||
.PP
|
||||
The \fIclientData\fR and \fIinterp\fR parameters to \fIproc\fR
|
||||
will be copies of the corresponding arguments to
|
||||
\fBTk_GetSelection\fR. \fIPortion\fR will be a pointer to
|
||||
a string containing part or all of the selection. For large
|
||||
@@ -68,10 +69,10 @@ been completely retrieved and processed by \fIproc\fR, or when a
|
||||
fatal error has occurred (e.g. the selection owner did not respond
|
||||
promptly). \fBTk_GetSelection\fR normally returns \fBTCL_OK\fR; if
|
||||
an error occurs, it returns \fBTCL_ERROR\fR and leaves an error message
|
||||
in \fIinterp->result\fR. \fIProc\fR should also return either
|
||||
\fBTCL_OK\fR or \fBTCL_ERROR\fR. If \fIproc\fR encounters an error in dealing with the
|
||||
selection, it should leave an error message in \fIinterp->result\fR
|
||||
and return \fBTCL_ERROR\fR; this will abort the selection retrieval.
|
||||
|
||||
in interpreter \fIinterp\fR's result. \fIProc\fR should also return either
|
||||
\fBTCL_OK\fR or \fBTCL_ERROR\fR. If \fIproc\fR encounters an error in
|
||||
dealing with the selection, it should leave an error message in the
|
||||
interpreter result and return \fBTCL_ERROR\fR; this will abort the
|
||||
selection retrieval.
|
||||
.SH KEYWORDS
|
||||
format, get, selection retrieval
|
||||
|
||||
@@ -21,7 +21,6 @@ Tk_Uid
|
||||
String for which the corresponding unique identifier is
|
||||
desired.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GetUid\fR returns the unique identifier corresponding
|
||||
@@ -42,6 +41,5 @@ Tk_Uid may be compared directly (x == y) without having to call
|
||||
\fBstrcmp\fR.
|
||||
In addition, the return value from \fBTk_GetUid\fR will have the
|
||||
same string value as its argument (strcmp(Tk_GetUid(a), a) == 0).
|
||||
|
||||
.SH KEYWORDS
|
||||
atom, unique identifier
|
||||
|
||||
@@ -28,7 +28,6 @@ Points to word in which to store width of virtual root.
|
||||
.AP "int" heightPtr out
|
||||
Points to word in which to store height of virtual root.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GetVRootGeometry\fR returns geometry information about the virtual
|
||||
@@ -43,6 +42,5 @@ If \fItkwin\fR is not associated with a virtual root (e.g.
|
||||
because the window manager does not use virtual roots) then *\fIxPtr\fR and
|
||||
*\fIyPtr\fR will be set to 0 and *\fIwidthPtr\fR and *\fIheightPtr\fR
|
||||
will be set to the dimensions of the screen containing \fItkwin\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
geometry, height, location, virtual root, width, window manager
|
||||
|
||||
@@ -39,7 +39,7 @@ It returns a pointer to the X Visual structure for the visual
|
||||
and stores the number of bits per pixel for it at \fI*depthPtr\fR.
|
||||
If \fIstring\fR is unrecognizable or if no suitable visual could
|
||||
be found, then NULL is returned and \fBTk_GetVisual\fR leaves
|
||||
an error message in \fIinterp->result\fR.
|
||||
an error message in interpreter \fIinterp\fR's result.
|
||||
If \fIcolormap\fR is non-NULL then \fBTk_GetVisual\fR
|
||||
also locates an appropriate colormap for use with the result visual
|
||||
and stores its X identifier at \fI*colormapPtr\fR.
|
||||
|
||||
@@ -16,7 +16,6 @@ int
|
||||
.sp
|
||||
void
|
||||
\fBTk_Ungrab\fR(\fItkwin\fR)
|
||||
|
||||
.SH ARGUMENTS
|
||||
.AP Tcl_Interp *interp in
|
||||
Interpreter to use for error reporting
|
||||
@@ -25,7 +24,6 @@ Window on whose behalf the pointer is to be grabbed or released
|
||||
.AP int grabGlobal in
|
||||
Boolean indicating whether the grab is global or application local
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These functions are used to set or release a global or
|
||||
@@ -39,7 +37,6 @@ intended for windows in other applications) will be redirected to
|
||||
\fItkwin\fR. If the grab is application local, only mouse and
|
||||
keyboard events intended for a windows within the same application
|
||||
(but outside the tree rooted at \fItkwin\fR) will be redirected.
|
||||
|
||||
.PP
|
||||
\fBTk_Grab\fR sets a grab on a particular window. \fITkwin\fR
|
||||
specifies the window on whose behalf the pointer is to be grabbed.
|
||||
@@ -52,12 +49,10 @@ successfully, no window outside the tree rooted at \fItkwin\fR will
|
||||
receive pointer- or keyboard-related events until the next call to
|
||||
Tk_Ungrab. If a previous grab was in effect within the application,
|
||||
then it is replaced with a new one.
|
||||
|
||||
.PP
|
||||
\fBTcl_Ungrab\fR releases a grab on the mouse pointer and keyboard, if
|
||||
\fBTk_Ungrab\fR releases a grab on the mouse pointer and keyboard, if
|
||||
there is one set on the window given by \fItkwin\fR. Once a grab is
|
||||
released, pointer and keyboard events will start being delivered to
|
||||
other windows again.
|
||||
|
||||
.SH KEYWORDS
|
||||
grab, window
|
||||
|
||||
@@ -17,12 +17,10 @@ Tk_Window
|
||||
.AP HWND hwnd in
|
||||
Windows handle for the window.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
Given a Windows HWND window identifier, this procedure returns the
|
||||
corresponding Tk_Window handle. If there is no Tk_Window corresponding
|
||||
to \fIhwnd\fR then NULL is returned.
|
||||
|
||||
.SH KEYWORDS
|
||||
Windows window id
|
||||
|
||||
@@ -21,12 +21,11 @@ Tk_HandleEvent \- invoke event handlers for window system events
|
||||
Pointer to X event to dispatch to relevant handler(s). It is important
|
||||
that all unused fields of the structure be set to zero.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_HandleEvent\fR is a lower-level procedure that deals with window
|
||||
events. It is called by \fBTcl_ServiceEvent\fR (and indirectly by
|
||||
\fBTcl_DoOneEvent\fR), and in a few other cases within Tk.
|
||||
\fBTk_DoOneEvent\fR), and in a few other cases within Tk.
|
||||
It makes callbacks to any window event
|
||||
handlers (created by calls to \fBTk_CreateEventHandler\fR)
|
||||
that match \fIeventPtr\fR and then returns. In some cases
|
||||
@@ -43,6 +42,5 @@ as when a
|
||||
notifier has been popped up and an application wishes to
|
||||
wait for the user to click a button in the notifier before
|
||||
doing anything else.
|
||||
|
||||
.SH KEYWORDS
|
||||
callback, event, handler, window
|
||||
|
||||
@@ -22,13 +22,11 @@ X display containing the window.
|
||||
.AP Window window in
|
||||
X id for window.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
Given an X window identifier and the X display it corresponds to,
|
||||
this procedure returns the corresponding Tk_Window handle.
|
||||
If there is no Tk_Window corresponding to \fIwindow\fR then
|
||||
NULL is returned.
|
||||
|
||||
.SH KEYWORDS
|
||||
X window id
|
||||
|
||||
@@ -35,7 +35,6 @@ Current width of image, in pixels.
|
||||
.AP "int" imageHeight in
|
||||
Current height of image, in pixels.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
An image manager calls \fBTk_ImageChanged\fR for an image
|
||||
@@ -59,9 +58,7 @@ that changed.
|
||||
If the size of the image should change, then \fBTk_ImageChanged\fR
|
||||
must be called to indicate the new size, even if no pixels
|
||||
need to be redisplayed.
|
||||
|
||||
.SH "SEE ALSO"
|
||||
Tk_CreateImageType
|
||||
|
||||
.SH KEYWORDS
|
||||
images, redisplay, image size changes
|
||||
|
||||
@@ -21,7 +21,6 @@ long
|
||||
The display on which the user inactivity timer is to be queried or
|
||||
reset.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_GetUserInactiveTime\fR returns the number of milliseconds that
|
||||
@@ -31,6 +30,5 @@ support querying the user inactiviy time, \fB\-1\fR is returned.
|
||||
\fBTk_GetUserInactiveTime\fR resets the user inactivity timer of the
|
||||
given display to zero. On windowing systems that do not support
|
||||
multiple displays \fIdisplay\fR can be passed as \fBNULL\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
idle, inactive
|
||||
|
||||
@@ -28,7 +28,6 @@ String name for which atom is desired.
|
||||
.AP Atom atom in
|
||||
Atom for which corresponding string name is desired.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures are similar to the Xlib procedures
|
||||
@@ -52,6 +51,5 @@ for the same information can be serviced from the cache without
|
||||
contacting the server. Thus \fBTk_InternAtom\fR and \fBTk_GetAtomName\fR
|
||||
are generally much faster than their Xlib counterparts, and they
|
||||
should be used in place of the Xlib procedures.
|
||||
|
||||
.SH KEYWORDS
|
||||
atom, cache, display
|
||||
|
||||
@@ -16,7 +16,6 @@ Tk_MainLoop \- loop for events until all windows are deleted
|
||||
.sp
|
||||
\fBTk_MainLoop\fR()
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_MainLoop\fR is a procedure that loops repeatedly calling
|
||||
@@ -25,6 +24,5 @@ left in this process (i.e. no main windows exist anymore). Most
|
||||
windowing applications will call \fBTk_MainLoop\fR after
|
||||
initialization; the main execution of the application will consist
|
||||
entirely of callbacks invoked via \fBTcl_DoOneEvent\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
application, event, main loop
|
||||
|
||||
@@ -9,8 +9,7 @@
|
||||
.so man.macros
|
||||
.BS
|
||||
.SH NAME
|
||||
Tk_MainWindow, Tk_GetNumMainWindows \- functions for querying main
|
||||
window information
|
||||
Tk_MainWindow, Tk_GetNumMainWindows \- functions for querying main window information
|
||||
.SH SYNOPSIS
|
||||
.nf
|
||||
\fB#include <tk.h>\fR
|
||||
@@ -20,13 +19,11 @@ Tk_Window
|
||||
.sp
|
||||
int
|
||||
\fBTk_GetNumMainWindows\fR()
|
||||
|
||||
.SH ARGUMENTS
|
||||
.AS Tcl_Interp *pathName
|
||||
.AP Tcl_Interp *interp in/out
|
||||
Interpreter associated with the application.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
A main window is a special kind of toplevel window used as the
|
||||
@@ -35,10 +32,9 @@ outermost window in an application.
|
||||
If \fIinterp\fR is associated with a Tk application then \fBTk_MainWindow\fR
|
||||
returns the application's main window. If there is no Tk application
|
||||
associated with \fIinterp\fR then \fBTk_MainWindow\fR returns NULL and
|
||||
leaves an error message in \fIinterp->result\fR.
|
||||
leaves an error message in interpreter \fIinterp\fR's result.
|
||||
.PP
|
||||
\fBTk_GetNumMainWindows\fR returns a count of the number of main
|
||||
windows currently open in the process.
|
||||
|
||||
windows currently open in the current thread.
|
||||
.SH KEYWORDS
|
||||
application, main window
|
||||
|
||||
@@ -36,7 +36,6 @@ Desired width for \fIslave\fR, in pixels.
|
||||
.AP int height in
|
||||
Desired height for \fIslave\fR, in pixels.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_MaintainGeometry\fR and \fBTk_UnmaintainGeometry\fR make it
|
||||
|
||||
@@ -45,7 +45,7 @@ typedef struct {
|
||||
const char *\fIname\fR;
|
||||
Tk_GeomRequestProc *\fIrequestProc\fR;
|
||||
Tk_GeomLostSlaveProc *\fIlostSlaveProc\fR;
|
||||
} Tk_GeomMgr;
|
||||
} \fBTk_GeomMgr\fR;
|
||||
.CE
|
||||
The \fIname\fR field is the textual name for the geometry manager,
|
||||
such as \fBpack\fR or \fBplace\fR; this value will be returned
|
||||
@@ -57,9 +57,9 @@ slave to change its desired geometry.
|
||||
\fIrequestProc\fR should have arguments and results that match the
|
||||
type \fBTk_GeomRequestProc\fR:
|
||||
.CS
|
||||
typedef void Tk_GeomRequestProc(
|
||||
ClientData \fIclientData\fR,
|
||||
Tk_Window \fItkwin\fR);
|
||||
typedef void \fBTk_GeomRequestProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
Tk_Window \fItkwin\fR);
|
||||
.CE
|
||||
The parameters to \fIrequestProc\fR will be identical to the
|
||||
corresponding parameters passed to \fBTk_ManageGeometry\fR.
|
||||
@@ -80,12 +80,11 @@ is the same as the window's current geometry manager.
|
||||
\fIlostSlaveProc\fR should have
|
||||
arguments and results that match the following prototype:
|
||||
.CS
|
||||
typedef void Tk_GeomLostSlaveProc(
|
||||
ClientData \fIclientData\fR,
|
||||
Tk_Window \fItkwin\fR);
|
||||
typedef void \fBTk_GeomLostSlaveProc\fR(
|
||||
ClientData \fIclientData\fR,
|
||||
Tk_Window \fItkwin\fR);
|
||||
.CE
|
||||
The parameters to \fIlostSlaveProc\fR will be identical to the
|
||||
corresponding parameters passed to \fBTk_ManageGeometry\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
callback, geometry, managed, request, unmanaged
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_MapWindow 3 "" Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -23,7 +23,6 @@ Tk_Window
|
||||
.AP Tk_Window tkwin in
|
||||
Token for window.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These procedures may be used to map and unmap windows
|
||||
@@ -36,9 +35,9 @@ deferred window creation.
|
||||
from the screen.
|
||||
.PP
|
||||
If \fItkwin\fR is a child window (i.e. \fBTk_CreateWindow\fR was
|
||||
used to create a child window), then event handlers interested in map
|
||||
and unmap events are invoked immediately. If \fItkwin\fR is not an
|
||||
internal window, then the event handlers will be invoked later, after
|
||||
used to create a child window), then event handlers interested in map
|
||||
and unmap events are invoked immediately. If \fItkwin\fR is not an
|
||||
internal window, then the event handlers will be invoked later, after
|
||||
X has seen the request and returned an event for it.
|
||||
.PP
|
||||
These procedures should be used in place of the X procedures
|
||||
@@ -46,6 +45,5 @@ These procedures should be used in place of the X procedures
|
||||
Tk's local data structure for \fItkwin\fR. Applications
|
||||
using Tk should not invoke \fBXMapWindow\fR and \fBXUnmapWindow\fR
|
||||
directly.
|
||||
|
||||
.SH KEYWORDS
|
||||
map, unmap, window
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_MeasureChars 3 8.1 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -32,7 +32,7 @@ returned by a previous call to \fBTk_GetFont\fR.
|
||||
Text to be measured or displayed. Need not be null terminated. Any
|
||||
non-printing meta-characters in the string (such as tabs, newlines, and
|
||||
other control characters) will be measured or displayed in a
|
||||
platform-dependent manner.
|
||||
platform-dependent manner.
|
||||
.AP int numBytes in
|
||||
The maximum number of bytes to consider when measuring or drawing
|
||||
\fIstring\fR. Must be greater than or equal to 0.
|
||||
@@ -60,11 +60,11 @@ Display on which to draw.
|
||||
.AP Drawable drawable in
|
||||
Window or pixmap in which to draw.
|
||||
.AP GC gc in
|
||||
Graphics context for drawing characters. The font selected into this GC
|
||||
Graphics context for drawing characters. The font selected into this GC
|
||||
must be the same as the \fItkfont\fR.
|
||||
.AP int "x, y" in
|
||||
Coordinates at which to place the left edge of the baseline when displaying
|
||||
\fIstring\fR.
|
||||
\fIstring\fR.
|
||||
.AP int firstByte in
|
||||
The index of the first byte of the first character to underline in the
|
||||
\fIstring\fR. Underlining begins at the left edge of this character.
|
||||
@@ -80,7 +80,7 @@ single-line strings. To measure and display single-font, multi-line,
|
||||
justified text, refer to the documentation for \fBTk_ComputeTextLayout\fR.
|
||||
There is no programming interface in the core of Tk that supports
|
||||
multi-font, multi-line text; support for that behavior must be built on
|
||||
top of simpler layers.
|
||||
top of simpler layers.
|
||||
Note that the interfaces described here are
|
||||
byte-oriented not character-oriented, so index values coming from Tcl
|
||||
scripts need to be converted to byte offsets using the
|
||||
@@ -95,7 +95,7 @@ escape sequences, while under Windows and Macintosh hollow or solid boxes
|
||||
may be substituted. Refer to the documentation for
|
||||
\fBTk_ComputeTextLayout\fR for a programming interface that supports the
|
||||
platform-independent expansion of tab characters into columns and
|
||||
newlines/returns into multi-line text.
|
||||
newlines/returns into multi-line text.
|
||||
.PP
|
||||
\fBTk_MeasureChars\fR is used both to compute the length of a given
|
||||
string and to compute how many characters from a string fit in a given
|
||||
@@ -106,12 +106,12 @@ value will be \fInumBytes\fR. \fI*lengthPtr\fR is filled with the computed
|
||||
width, in pixels, of the portion of the string that was measured. For
|
||||
example, if the return value is 5, then \fI*lengthPtr\fR is filled with the
|
||||
distance between the left edge of \fIstring\fR[0] and the right edge of
|
||||
\fIstring\fR[4].
|
||||
\fIstring\fR[4].
|
||||
.PP
|
||||
\fBTk_TextWidth\fR is a wrapper function that provides a simpler interface
|
||||
to the \fBTk_MeasureChars\fR function. The return value is how much
|
||||
space in pixels the given \fIstring\fR needs.
|
||||
.PP
|
||||
.PP
|
||||
\fBTk_DrawChars\fR draws the \fIstring\fR at the given location in the
|
||||
given \fIdrawable\fR.
|
||||
.PP
|
||||
@@ -120,7 +120,7 @@ given \fIstring\fR. It does not draw the characters (which are assumed to
|
||||
have been displayed previously by \fBTk_DrawChars\fR); it just draws the
|
||||
underline. This procedure is used to underline a few characters without
|
||||
having to construct an underlined font. To produce natively underlined
|
||||
text, the appropriate underlined font should be constructed and used.
|
||||
text, the appropriate underlined font should be constructed and used.
|
||||
.SH "SEE ALSO"
|
||||
font(n), FontId(3)
|
||||
.SH KEYWORDS
|
||||
|
||||
@@ -28,7 +28,6 @@ New y-coordinate for the top-left pixel of \fItkwin\fR's border, or the
|
||||
top-left pixel of the decorative border supplied for \fItkwin\fR by the
|
||||
window manager, if there is one.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
In general, a window should never set its own position; this should be
|
||||
@@ -48,6 +47,5 @@ When \fBTk_MoveToplevelWindow\fR is called it does not immediately
|
||||
pass on the new desired location to the window manager; it defers
|
||||
this action until all other outstanding work has been completed,
|
||||
using the \fBTk_DoWhenIdle\fR mechanism.
|
||||
|
||||
.SH KEYWORDS
|
||||
position, top-level window, window manager
|
||||
|
||||
@@ -31,7 +31,6 @@ Interpreter to use for error reporting.
|
||||
.AP "const char" *pathName in
|
||||
Character string containing path name of window.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
Each window managed by Tk has two names, a short name that identifies
|
||||
@@ -49,8 +48,7 @@ as a Tk_Uid, which may be used just like a string pointer but also has
|
||||
the properties of a unique identifier (see the manual entry for
|
||||
\fBTk_GetUid\fR for details).
|
||||
.PP
|
||||
The \fBTk_PathName\fR macro returns a
|
||||
hierarchical name for \fItkwin\fR.
|
||||
The \fBTk_PathName\fR macro returns a hierarchical name for \fItkwin\fR.
|
||||
Path names have a structure similar to file names in Unix but with
|
||||
dots between elements instead of slashes: the main window for
|
||||
an application has the path name
|
||||
@@ -75,7 +73,8 @@ The procedure \fBTk_NameToWindow\fR returns the token for a window
|
||||
given its path name (the \fIpathName\fR argument) and another window
|
||||
belonging to the same main window (\fItkwin\fR). It normally
|
||||
returns a token for the named window, but if no such window exists
|
||||
\fBTk_NameToWindow\fR leaves an error message in \fIinterp->result\fR
|
||||
\fBTk_NameToWindow\fR leaves an error message in interpreter
|
||||
\fIinterp\fR's result
|
||||
and returns NULL. The \fItkwin\fR argument to \fBTk_NameToWindow\fR
|
||||
is needed because path names are only unique within a single
|
||||
application hierarchy. If, for example, a single process has opened
|
||||
@@ -83,6 +82,5 @@ two main windows, each will have a separate naming hierarchy and the
|
||||
same path name might appear in each of the hierarchies. Normally
|
||||
\fItkwin\fR is the main window of the desired hierarchy, but this
|
||||
need not be the case: any window in the desired hierarchy may be used.
|
||||
|
||||
.SH KEYWORDS
|
||||
name, path name, token, window
|
||||
|
||||
@@ -21,12 +21,10 @@ const char *
|
||||
Token for image, which was passed to image manager's \fIcreateProc\fR when
|
||||
the image was created.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
This procedure is invoked by image managers to find out the name
|
||||
of an image. Given the token for the image, it returns the
|
||||
string name for the image.
|
||||
|
||||
.SH KEYWORDS
|
||||
image manager, image name
|
||||
|
||||
@@ -26,7 +26,6 @@ Procedure to invoke when \fItkwin\fR loses selection ownership later.
|
||||
.AP ClientData clientData in
|
||||
Arbitrary one-word value to pass to \fIproc\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_OwnSelection\fR arranges for \fItkwin\fR to become the
|
||||
@@ -39,12 +38,12 @@ invoked so that the window can clean itself up (e.g. by
|
||||
unhighlighting the selection). \fIProc\fR should have arguments and
|
||||
result that match the type \fBTk_LostSelProc\fR:
|
||||
.CS
|
||||
typedef void Tk_LostSelProc(ClientData \fIclientData\fR);
|
||||
typedef void \fBTk_LostSelProc\fR(
|
||||
ClientData \fIclientData\fR);
|
||||
.CE
|
||||
The \fIclientData\fR parameter to \fIproc\fR is a copy of the
|
||||
\fIclientData\fR argument given to \fBTk_OwnSelection\fR, and is
|
||||
usually a pointer to a data structure containing application-specific
|
||||
information about \fItkwin\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
own, selection owner
|
||||
|
||||
@@ -60,8 +60,8 @@ elements of \fIargv\fR.
|
||||
.PP
|
||||
\fBTk_ParseArgv\fR normally returns the value \fBTCL_OK\fR. If an error
|
||||
occurs while parsing the arguments, then \fBTCL_ERROR\fR is returned and
|
||||
\fBTk_ParseArgv\fR will leave an error message in \fIinterp->result\fR
|
||||
in the standard Tcl fashion. In
|
||||
\fBTk_ParseArgv\fR will leave an error message in the result of
|
||||
interpreter \fIinterp\fR in the standard Tcl fashion. In
|
||||
the event of an error return, \fI*argvPtr\fR will not have been
|
||||
modified, but \fIargv\fR could have been partially modified. The
|
||||
possible causes of errors are explained below.
|
||||
@@ -70,12 +70,12 @@ The \fIargTable\fR array specifies the kinds of arguments that are
|
||||
expected; each of its entries has the following structure:
|
||||
.CS
|
||||
typedef struct {
|
||||
char *\fIkey\fR;
|
||||
const char *\fIkey\fR;
|
||||
int \fItype\fR;
|
||||
char *\fIsrc\fR;
|
||||
char *\fIdst\fR;
|
||||
char *\fIhelp\fR;
|
||||
} Tk_ArgvInfo;
|
||||
const char *\fIhelp\fR;
|
||||
} \fBTk_ArgvInfo\fR;
|
||||
.CE
|
||||
The \fIkey\fR field is a string such as
|
||||
.QW \-display
|
||||
@@ -186,7 +186,8 @@ specifiers of this type are ignored (as if they did not exist).
|
||||
\fBTK_ARGV_HELP\fR
|
||||
When this kind of option is encountered, \fBTk_ParseArgv\fR uses the
|
||||
\fIhelp\fR fields of \fIargTable\fR to format a message describing
|
||||
all the valid arguments. The message is placed in \fIinterp->result\fR
|
||||
all the valid arguments. The message is placed in interpreter
|
||||
\fIinterp\fR's result
|
||||
and \fBTk_ParseArgv\fR returns \fBTCL_ERROR\fR. When this happens, the
|
||||
caller normally prints the help message and aborts. If the \fIkey\fR
|
||||
field of a \fBTK_ARGV_HELP\fR specifier is NULL, then the specifier will
|
||||
@@ -259,11 +260,12 @@ then return any that are left by compacting them to the beginning of
|
||||
\fIargv\fR (starting at \fIargv\fR[0]). \fIGenfunc\fR
|
||||
should return a count of how many arguments are left in \fIargv\fR;
|
||||
\fBTk_ParseArgv\fR will process them. If \fIgenfunc\fR encounters
|
||||
an error then it should leave an error message in \fIinterp->result\fR,
|
||||
an error then it should leave an error message in interpreter
|
||||
\fIinterp\fR's result,
|
||||
in the usual Tcl fashion, and return \-1; when this happens
|
||||
\fBTk_ParseArgv\fR will abort its processing and return \fBTCL_ERROR\fR.
|
||||
.RE
|
||||
.SH "FLAGS"
|
||||
.SS "FLAGS"
|
||||
.TP
|
||||
\fBTK_ARGV_DONT_SKIP_FIRST_ARG\fR
|
||||
\fBTk_ParseArgv\fR normally treats \fIargv[0]\fR as a program
|
||||
@@ -329,7 +331,7 @@ main(argc, argv)
|
||||
\&...
|
||||
|
||||
if (Tk_ParseArgv(interp, tkwin, &argc, argv, argTable, 0) != TCL_OK) {
|
||||
fprintf(stderr, "%s\en", interp->result);
|
||||
fprintf(stderr, "%s\en", Tcl_GetString(Tcl_GetObjResult(interp)));
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
||||
@@ -30,7 +30,6 @@ that all unused fields of the structure be set to zero.
|
||||
Where to add the new event in the queue: \fBTCL_QUEUE_TAIL\fR,
|
||||
\fBTCL_QUEUE_HEAD\fR, or \fBTCL_QUEUE_MARK\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_QueueWindowEvent\fR places a window event on Tcl's internal event
|
||||
@@ -47,6 +46,5 @@ returns the previous value for collapse behavior on the \fIdisplay\fR.
|
||||
The \fIposition\fR argument to \fBTk_QueueWindowEvent\fR has
|
||||
the same significance as for \fBTcl_QueueEvent\fR; see the
|
||||
documentation for \fBTcl_QueueEvent\fR for details.
|
||||
|
||||
.SH KEYWORDS
|
||||
callback, clock, handler, modal timeout, events
|
||||
|
||||
@@ -28,7 +28,6 @@ must be \fBAbove\fR or \fBBelow\fR.
|
||||
Must be a sibling of \fItkwin\fR or a descendant of a sibling.
|
||||
If NULL then \fItkwin\fR is restacked above or below all siblings.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_RestackWindow\fR changes the stacking order of \fIwindow\fR relative
|
||||
@@ -42,6 +41,5 @@ just above or below \fIother\fR.
|
||||
The \fIaboveBelow\fR argument must have one of the symbolic values
|
||||
\fBAbove\fR or \fBBelow\fR.
|
||||
Both of these values are defined by the include file <X11/Xlib.h>.
|
||||
|
||||
.SH KEYWORDS
|
||||
above, below, obscure, stacking order
|
||||
|
||||
@@ -15,18 +15,17 @@ Tk_RestrictEvents \- filter and selectively delay X events
|
||||
\fB#include <tk.h>\fR
|
||||
.sp
|
||||
Tk_RestrictProc *
|
||||
\fBTk_RestrictEvents\fR(\fIproc, clientData, prevClientDataPtr\fR)
|
||||
\fBTk_RestrictEvents\fR(\fIproc, arg, prevArgPtr\fR)
|
||||
.SH ARGUMENTS
|
||||
.AS Tk_RestrictProc **prevClientDataPtr
|
||||
.AS Tk_RestrictProc **prevArgPtr
|
||||
.AP Tk_RestrictProc *proc in
|
||||
Predicate procedure to call to filter incoming X events.
|
||||
NULL means do not restrict events at all.
|
||||
.AP ClientData clientData in
|
||||
.AP ClientData arg in
|
||||
Arbitrary argument to pass to \fIproc\fR.
|
||||
.AP ClientData *prevClientDataPtr out
|
||||
.AP ClientData *prevArgPtr out
|
||||
Pointer to place to save argument to previous restrict procedure.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
This procedure is useful in certain situations where applications
|
||||
@@ -40,11 +39,11 @@ later time (e.g. when the event restriction is lifted), or discarded.
|
||||
is a procedure with arguments and result that match
|
||||
the type \fBTk_RestrictProc\fR:
|
||||
.CS
|
||||
typedef Tk_RestrictAction Tk_RestrictProc(
|
||||
ClientData \fIclientData\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
typedef Tk_RestrictAction \fBTk_RestrictProc\fR(
|
||||
ClientData \fIarg\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
.CE
|
||||
The \fIclientData\fR argument is a copy of the \fIclientData\fR passed
|
||||
The \fIarg\fR argument is a copy of the \fIarg\fR passed
|
||||
to \fBTk_RestrictEvents\fR; it may be used to provide \fIproc\fR with
|
||||
information it needs to filter events. The \fIeventPtr\fR points to
|
||||
an event under consideration. \fIProc\fR returns a restrict action
|
||||
@@ -56,7 +55,7 @@ left on the event queue for later processing. If the return value is
|
||||
\fBTK_DISCARD_EVENT\fR, then the event will be removed from the event
|
||||
queue and discarded without being processed.
|
||||
.PP
|
||||
\fBTk_RestrictEvents\fR uses its return value and \fIprevClientDataPtr\fR
|
||||
\fBTk_RestrictEvents\fR uses its return value and \fIprevArgPtr\fR
|
||||
to return information about the current event restriction procedure
|
||||
(a NULL return value means there are currently no restrictions).
|
||||
These values may be used to restore the previous restriction state
|
||||
|
||||
@@ -24,7 +24,6 @@ application.
|
||||
.AP "const char" *name in
|
||||
Name under which to register the application.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_SetAppName\fR associates a name with a given application and
|
||||
@@ -59,6 +58,5 @@ so applications do not normally need to call it explicitly.
|
||||
.PP
|
||||
The command \fBtk appname\fR provides Tcl-level access to the
|
||||
functionality of \fBTk_SetAppName\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
application, name, register, send command
|
||||
|
||||
@@ -25,7 +25,6 @@ Window-relative y coordinate.
|
||||
.AP int h in
|
||||
Height of the caret in the window.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_SetCaretPos\fR sets the caret location for the display of the
|
||||
@@ -33,6 +32,5 @@ specified Tk_Window \fItkwin\fR. The caret is the per-display cursor
|
||||
location used for indicating global focus (e.g. to comply with Microsoft
|
||||
Accessibility guidelines), as well as for location of the over-the-spot XIM
|
||||
(X Input Methods) or Windows IME windows.
|
||||
|
||||
.SH KEYWORDS
|
||||
caret, cursor
|
||||
|
||||
@@ -25,7 +25,6 @@ Token for window.
|
||||
.AP char *class in
|
||||
New class name for window.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_SetClass\fR is called to associate a class with a particular
|
||||
@@ -54,6 +53,5 @@ the properties of a unique identifier (see the manual entry for
|
||||
\fBTk_GetUid\fR for details).
|
||||
If \fItkwin\fR has not yet been given a class, then
|
||||
\fBTk_Class\fR will return NULL.
|
||||
|
||||
.SH KEYWORDS
|
||||
class, unique identifier, window, window manager
|
||||
|
||||
@@ -18,14 +18,13 @@ Tk_SetClassProcs \- register widget specific procedures
|
||||
.AS Tk_ClassProc instanceData
|
||||
.AP Tk_Window tkwin in
|
||||
Token for window to modify.
|
||||
.AP Tk_ClassProcs *procs in
|
||||
.AP "const Tk_ClassProcs" *procs in
|
||||
Pointer to data structure containing widget specific procedures.
|
||||
The data structure pointed to by \fIprocs\fR must be static:
|
||||
Tk keeps a reference to it as long as the window exists.
|
||||
.AP ClientData instanceData in
|
||||
Arbitrary one-word value to pass to widget callbacks.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_SetClassProcs\fR is called to register a set of procedures that
|
||||
@@ -38,7 +37,7 @@ typedef struct Tk_ClassProcs {
|
||||
Tk_ClassWorldChangedProc *\fIworldChangedProc\fR;
|
||||
Tk_ClassCreateProc *\fIcreateProc\fR;
|
||||
Tk_ClassModalProc *\fImodalProc\fR;
|
||||
} Tk_ClassProcs;
|
||||
} \fBTk_ClassProcs\fR;
|
||||
.CE
|
||||
The \fIsize\fR field is used to simplify future expansion of the
|
||||
structure. It should always be set to (literally) \fBsizeof(Tk_ClassProcs)\fR.
|
||||
@@ -50,8 +49,8 @@ widgets configured to use that font alias must update their display
|
||||
accordingly. \fIworldChangedProc\fR should have arguments and results
|
||||
that match the type \fBTk_ClassWorldChangedProc\fR:
|
||||
.CS
|
||||
typedef void Tk_ClassWorldChangedProc(
|
||||
ClientData \fIinstanceData\fR);
|
||||
typedef void \fBTk_ClassWorldChangedProc\fR(
|
||||
ClientData \fIinstanceData\fR);
|
||||
.CE
|
||||
The \fIinstanceData\fR parameter passed to the \fIworldChangedProc\fR
|
||||
will be identical to the \fIinstanceData\fR parameter passed to
|
||||
@@ -61,10 +60,10 @@ will be identical to the \fIinstanceData\fR parameter passed to
|
||||
invoked by \fBTk_MakeWindowExist\fR. \fIcreateProc\fR should have
|
||||
arguments and results that match the type \fBTk_ClassCreateProc\fR:
|
||||
.CS
|
||||
typedef Window Tk_ClassCreateProc(
|
||||
Tk_Window \fItkwin\fR,
|
||||
Window \fIparent\fR,
|
||||
ClientData \fIinstanceData\fR);
|
||||
typedef Window \fBTk_ClassCreateProc\fR(
|
||||
Tk_Window \fItkwin\fR,
|
||||
Window \fIparent\fR,
|
||||
ClientData \fIinstanceData\fR);
|
||||
.CE
|
||||
The \fItkwin\fR and \fIinstanceData\fR parameters will be identical to
|
||||
the \fItkwin\fR and \fIinstanceData\fR parameters passed to
|
||||
@@ -76,14 +75,13 @@ created window.
|
||||
triggered in order to handle a modal loop. \fImodalProc\fR should
|
||||
have arguments and results that match the type \fBTk_ClassModalProc\fR:
|
||||
.CS
|
||||
typedef void Tk_ClassModalProc(
|
||||
Tk_Window \fItkwin\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
typedef void \fBTk_ClassModalProc\fR(
|
||||
Tk_Window \fItkwin\fR,
|
||||
XEvent *\fIeventPtr\fR);
|
||||
.CE
|
||||
The \fItkwin\fR parameter to \fImodalProc\fR will be identical to the
|
||||
\fItkwin\fR parameter passed to \fBTk_SetClassProcs\fR. The
|
||||
\fIeventPtr\fR parameter will be a pointer to an XEvent structure
|
||||
describing the event being processed.
|
||||
|
||||
.SH KEYWORDS
|
||||
callback, class
|
||||
|
||||
@@ -32,7 +32,6 @@ Width of one grid unit, in pixels.
|
||||
.AP int heightInc in
|
||||
Height of one grid unit, in pixels.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_SetGrid\fR turns on gridded geometry management for \fItkwin\fR's
|
||||
@@ -60,6 +59,5 @@ toplevel, the calls for the new window have no effect.
|
||||
.PP
|
||||
See the \fBwm\fR manual entry for additional information on gridded geometry
|
||||
management.
|
||||
|
||||
.SH KEYWORDS
|
||||
grid, window, window manager
|
||||
|
||||
@@ -261,7 +261,7 @@ typedef struct {
|
||||
int \fIobjOffset\fR;
|
||||
int \fIinternalOffset\fR;
|
||||
int \fIflags\fR;
|
||||
ClientData \fIclientData\fR;
|
||||
const void *\fIclientData\fR;
|
||||
int \fItypeMask\fR;
|
||||
} \fBTk_OptionSpec\fR;
|
||||
.CE
|
||||
|
||||
@@ -28,7 +28,6 @@ Number of bits per pixel desired for \fItkwin\fR.
|
||||
New colormap for \fItkwin\fR, which must be compatible with
|
||||
\fIvisual\fR and \fIdepth\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
When Tk creates a new window it assigns it the default visual
|
||||
@@ -47,6 +46,5 @@ completed successfully.
|
||||
Note: \fBTk_SetWindowVisual\fR should not be called if you just want
|
||||
to change a window's colormap without changing its visual or depth;
|
||||
call \fBTk_SetWindowColormap\fR instead.
|
||||
|
||||
.SH KEYWORDS
|
||||
colormap, depth, visual
|
||||
|
||||
@@ -20,7 +20,6 @@ int
|
||||
.AP Tk_Window tkwin in
|
||||
Token for window.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
This procedure returns the current value of the \fBtk_strictMotif\fR
|
||||
@@ -35,6 +34,5 @@ is good enough, and extra features are welcome.
|
||||
This procedure uses a link to the Tcl variable to provide much
|
||||
faster access to the variable's value than could be had by calling
|
||||
\fBTcl_GetVar\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
Motif compliance, tk_strictMotif variable
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_ComputeTextLayout 3 8.1 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -39,7 +39,6 @@ int
|
||||
.sp
|
||||
void
|
||||
\fBTk_TextLayoutToPostscript(\fIinterp, layout\fB)\fR
|
||||
|
||||
.SH ARGUMENTS
|
||||
.AS Tk_TextLayout "*xPtr, *yPtr"
|
||||
.AP Tk_Font tkfont in
|
||||
@@ -49,7 +48,7 @@ have been returned by a previous call to \fBTk_GetFont\fR.
|
||||
.AP "const char" *string in
|
||||
Potentially multi-line string whose dimensions are to be computed and
|
||||
stored in the text layout. The \fIstring\fR must remain valid for the
|
||||
lifetime of the text layout.
|
||||
lifetime of the text layout.
|
||||
.AP int numChars in
|
||||
The number of characters to consider from \fIstring\fR. If
|
||||
\fInumChars\fR is less than 0, then assumes \fIstring\fR is null
|
||||
@@ -78,7 +77,7 @@ measured and displayed in a platform-dependent manner as described in
|
||||
\fBTk_MeasureChars\fR, and will not have any special behaviors.
|
||||
.AP int *widthPtr out
|
||||
If non-NULL, filled with either the width, in pixels, of the widest
|
||||
line in the text layout, or the width, in pixels, of the bounding box for the
|
||||
line in the text layout, or the width, in pixels, of the bounding box for the
|
||||
character specified by \fIindex\fR.
|
||||
.AP int *heightPtr out
|
||||
If non-NULL, filled with either the total height, in pixels, of all
|
||||
@@ -102,7 +101,7 @@ text layout when it is being drawn, or the coordinates of a point (with
|
||||
respect to the upper-left hand corner of the text layout) to check
|
||||
against the text layout.
|
||||
.AP int firstChar in
|
||||
The index of the first character to draw from the given text layout.
|
||||
The index of the first character to draw from the given text layout.
|
||||
The number 0 means to draw from the beginning.
|
||||
.AP int lastChar in
|
||||
The index of the last character up to which to draw. The character
|
||||
@@ -120,13 +119,12 @@ for the character specified by \fIindex\fR. Either or both \fIxPtr\fR
|
||||
and \fIyPtr\fR may be NULL, in which case the corresponding value
|
||||
is not calculated.
|
||||
.AP int "width, height" in
|
||||
Specifies the width and height, in pixels, of the rectangular area to
|
||||
Specifies the width and height, in pixels, of the rectangular area to
|
||||
compare for intersection against the text layout.
|
||||
.AP Tcl_Interp *interp out
|
||||
Postscript code that will print the text layout is appended to
|
||||
\fIinterp->result\fR.
|
||||
the result of interpreter \fIinterp\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
These routines are for measuring and displaying single-font, multi-line,
|
||||
@@ -134,7 +132,7 @@ justified text. To measure and display simple single-font, single-line
|
||||
strings, refer to the documentation for \fBTk_MeasureChars\fR. There is
|
||||
no programming interface in the core of Tk that supports multi-font,
|
||||
multi-line text; support for that behavior must be built on top of
|
||||
simpler layers.
|
||||
simpler layers.
|
||||
Note that unlike the lower level text display routines, the functions
|
||||
described here all operate on character-oriented lengths and indices
|
||||
rather than byte-oriented values. See the description of
|
||||
@@ -152,11 +150,11 @@ returns a Tk_TextLayout token that holds this information. This token is
|
||||
used in subsequent calls to procedures such as \fBTk_DrawTextLayout\fR,
|
||||
\fBTk_DistanceToTextLayout\fR, and \fBTk_FreeTextLayout\fR. The
|
||||
\fIstring\fR and \fItkfont\fR used when computing the layout must remain
|
||||
valid for the lifetime of this token.
|
||||
valid for the lifetime of this token.
|
||||
.PP
|
||||
\fBTk_FreeTextLayout\fR is called to release the storage associated with
|
||||
\fIlayout\fR when it is no longer needed. A \fIlayout\fR should not be used
|
||||
in any other text layout procedures once it has been released.
|
||||
in any other text layout procedures once it has been released.
|
||||
.PP
|
||||
\fBTk_DrawTextLayout\fR uses the information in \fIlayout\fR to display a
|
||||
single-font, multi-line, justified string of text at the specified location.
|
||||
@@ -184,14 +182,16 @@ whose \fIx\fR-value is less than 0 will be considered closest to the first
|
||||
character on that line; any point whose \fIx\fR-value is greater than the
|
||||
width of the text layout will be considered closest to the last character on
|
||||
that line. The return value is the index of the character that was closest
|
||||
to the point. Given a \fIlayout\fR with no characters, the value 0 will
|
||||
always be returned, referring to a hypothetical zero-width placeholder
|
||||
character.
|
||||
to the point, or one more than the index of any character (to indicate that
|
||||
the point was after the end of the string and that the corresponding caret
|
||||
would be at the end of the string). Given a \fIlayout\fR with no characters,
|
||||
the value 0 will always be returned, referring to a hypothetical zero-width
|
||||
placeholder character.
|
||||
.PP
|
||||
\fBTk_CharBbox\fR uses the information in \fIlayout\fR to return the
|
||||
bounding box for the character specified by \fIindex\fR. The width of the
|
||||
bounding box is the advance width of the character, and does not include any
|
||||
left or right bearing. Any character that extends partially outside of
|
||||
left or right bearing. Any character that extends partially outside of
|
||||
\fIlayout\fR is considered to be truncated at the edge. Any character
|
||||
that would be located completely outside of \fIlayout\fR is considered to
|
||||
be zero-width and pegged against the edge. The height of the bounding
|
||||
@@ -231,8 +231,9 @@ array of strings that represent the individual lines in \fIlayout\fR. It
|
||||
is the responsibility of the caller to take the Postscript array of
|
||||
strings and add some Postscript function operate on the array to render
|
||||
each of the lines. The code that represents the Postscript array of
|
||||
strings is appended to \fIinterp->result\fR.
|
||||
strings is appended to interpreter \fIinterp\fR's result.
|
||||
.SH "DISPLAY MODEL"
|
||||
.PP
|
||||
When measuring a text layout, space characters that occur at the end of a
|
||||
line are ignored. The space characters still exist and the insertion point
|
||||
can be positioned amongst them, but their additional width is ignored when
|
||||
@@ -263,13 +264,13 @@ much as fits placed on the line and the rest on subsequent line(s). If
|
||||
\fIwrapLength\fR is so small that not even one character can fit on a
|
||||
given line, the \fIwrapLength\fR is ignored for that line and one
|
||||
character will be placed on the line anyhow. When wrapping is turned
|
||||
off, only newline/return characters may cause a line break.
|
||||
off, only newline/return characters may cause a line break.
|
||||
.PP
|
||||
When a text layout has been created using an underlined \fItkfont\fR,
|
||||
then any space characters that occur at the end of individual lines,
|
||||
newlines/returns, and tabs will not be displayed underlined when
|
||||
newlines/returns, and tabs will not be displayed underlined when
|
||||
\fBTk_DrawTextLayout\fR is called, because those characters are never
|
||||
actually drawn \- they are merely placeholders maintained in the
|
||||
\fIlayout\fR.
|
||||
\fIlayout\fR.
|
||||
.SH KEYWORDS
|
||||
font
|
||||
|
||||
@@ -34,7 +34,7 @@ as \fIversion\fR.
|
||||
The Tcl stubs mechanism defines a way to dynamically bind
|
||||
extensions to a particular Tcl implementation at run time.
|
||||
the stubs mechanism requires no changes to applications
|
||||
incoporating Tcl/Tk interpreters. Only developers creating
|
||||
incorporating Tcl/Tk interpreters. Only developers creating
|
||||
C-based Tcl/Tk extensions need to take steps to use the
|
||||
stubs mechanism with their extensions.
|
||||
See the \fBTcl_InitStubs\fR page for more information.
|
||||
@@ -48,15 +48,19 @@ Tcl functions.
|
||||
Call \fBTk_InitStubs\fR if the extension before calling any other
|
||||
Tk functions.
|
||||
.IP 2) 5
|
||||
Define the \fBUSE_TCL_STUBS\fR symbol. Typically, you would include the
|
||||
\fB\-DUSE_TCL_STUBS\fR flag when compiling the extension.
|
||||
Define the \fBUSE_TCL_STUBS\fR and the \fBUSE_TK_STUBS\fR
|
||||
symbols. Typically, you would include the \fB\-DUSE_TCL_STUBS\fR and
|
||||
the \fB\-DUSE_TK_STUBS\fR flags when compiling the extension.
|
||||
.IP 3) 5
|
||||
Link the extension with the Tcl and Tk stubs libraries instead of
|
||||
the standard Tcl and Tk libraries. On Unix platforms, the library
|
||||
names are \fIlibtclstub8.4.a\fR and \fIlibtkstub8.4.a\fR; on Windows
|
||||
platforms, the library names are \fItclstub84.lib\fR and \fItkstub84.lib\fR
|
||||
(adjust names with appropriate version number).
|
||||
Link the extension with the Tcl and Tk stubs libraries instead of the
|
||||
standard Tcl and Tk libraries. On Unix platforms, the library names
|
||||
are \fIlibtclstub8.4.a\fR and \fIlibtkstub8.4.a\fR; on Windows
|
||||
platforms, the library names are \fItclstub84.lib\fR and
|
||||
\fItkstub84.lib\fR. Adjust the library names with appropriate version
|
||||
number but note that the extension may only be used with versions of
|
||||
Tcl/Tk that have that version number or higher.
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_InitStubs\fR attempts to initialize the Tk stub table pointers
|
||||
and ensure that the correct version of Tk is loaded. In addition
|
||||
to an interpreter handle, it accepts as arguments a version number
|
||||
|
||||
@@ -23,7 +23,6 @@ int
|
||||
Interpreter in which to load Tk. Tk should not already be loaded
|
||||
in this interpreter.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_Init\fR is the package initialization procedure for Tk.
|
||||
@@ -34,7 +33,7 @@ and creates a new Tk application, including its main window.
|
||||
If the initialization is successful \fBTk_Init\fR returns
|
||||
\fBTCL_OK\fR; if there is an error it returns \fBTCL_ERROR\fR.
|
||||
\fBTk_Init\fR also leaves a result or error message
|
||||
in \fIinterp->result\fR.
|
||||
in interpreter \fIinterp\fR's result.
|
||||
.PP
|
||||
If there is a variable \fBargv\fR in \fIinterp\fR, \fBTk_Init\fR
|
||||
treats the contents of this variable as a list of options for the
|
||||
@@ -82,6 +81,5 @@ from the user.
|
||||
\fBwm\fR
|
||||
If toplevels are ever allowed, wm can be used to remove decorations,
|
||||
move windows around, etc.
|
||||
|
||||
.SH KEYWORDS
|
||||
safe, application, initialization, load, main window
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_Main 3 4.0 Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -20,16 +20,16 @@ Tk_Main \- main program for Tk-based applications
|
||||
.AP int argc in
|
||||
Number of elements in \fIargv\fR.
|
||||
.AP char *argv[] in
|
||||
Array of strings containing command-line arguments.
|
||||
Array of strings containing command-line arguments. On Windows, when
|
||||
using -DUNICODE, the parameter type changes to wchar_t *.
|
||||
.AP Tcl_AppInitProc *appInitProc in
|
||||
Address of an application-specific initialization procedure.
|
||||
The value for this argument is usually \fBTcl_AppInit\fR.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_Main\fR acts as the main program for most Tk-based applications.
|
||||
Starting with Tk 4.0 it is not called \fBmain\fR anymore because it
|
||||
Starting with Tk 4.0 it is not called \fBmain\fR anymore because it
|
||||
is part of the Tk library and having a function \fBmain\fR
|
||||
in a library (particularly a shared library) causes problems on many
|
||||
systems.
|
||||
@@ -50,11 +50,21 @@ for the application to perform its own initialization, such as defining
|
||||
application-specific commands. The procedure must have an interface
|
||||
that matches the type \fBTcl_AppInitProc\fR:
|
||||
.CS
|
||||
typedef int Tcl_AppInitProc(Tcl_Interp *\fIinterp\fR);
|
||||
typedef int \fBTcl_AppInitProc\fR(
|
||||
Tcl_Interp *\fIinterp\fR);
|
||||
.CE
|
||||
\fIAppInitProc\fR is almost always a pointer to \fBTcl_AppInit\fR;
|
||||
for more details on this procedure, see the documentation
|
||||
for \fBTcl_AppInit\fR.
|
||||
|
||||
.PP
|
||||
\fBTk_Main\fR functions much the same as \fBTcl_Main\fR. In particular,
|
||||
\fBTk_Main\fR supports both an interactive mode and a startup script
|
||||
mode, with the file name and encoding of a startup script under the
|
||||
control of the \fBTcl_SetStartupScript\fR and \fBTcl_GetStartupScript\fR
|
||||
routines. However it calls \fBTk_MainLoop\fR after processing any
|
||||
supplied script, and in interactive uses events registered with
|
||||
\fBTcl_CreateFileHandler\fR to process user input.
|
||||
.SH "SEE ALSO"
|
||||
Tcl_DoOneEvent(3)
|
||||
.SH KEYWORDS
|
||||
application-specific initialization, command-line arguments, main program
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH Tk_WindowId 3 "8.4" Tk "Tk Library Procedures"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -102,7 +102,6 @@ Tcl_Interp *
|
||||
.AP Tk_Window tkwin in
|
||||
Token for window.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
\fBTk_WindowId\fR and the other names listed above are
|
||||
@@ -169,7 +168,7 @@ the window's minimum requested size. These values correspond to the last
|
||||
call to \fBTk_SetMinimumRequestSize\fR for \fItkwin\fR.
|
||||
.PP
|
||||
\fBTk_InternalBorderLeft\fR, \fBTk_InternalBorderRight\fR,
|
||||
\fBTk_InternalBorderTop\fR and \fBTk_InternalBorderBottom\fR
|
||||
\fBTk_InternalBorderTop\fR and \fBTk_InternalBorderBottom\fR
|
||||
return the width of one side of the internal border
|
||||
that has been requested for \fItkwin\fR, or 0 if no internal border was
|
||||
requested. The return value is simply the last value passed to
|
||||
@@ -183,7 +182,6 @@ and \fBTk_Colormap\fR returns the current
|
||||
colormap for the window. The visual characteristics are
|
||||
normally set from the defaults for the window's screen, but
|
||||
they may be overridden by calling \fBTk_SetWindowVisual\fR.
|
||||
|
||||
.SH KEYWORDS
|
||||
attributes, colormap, depth, display, height, geometry manager,
|
||||
identifier, mapped, requested size, screen, top-level,
|
||||
|
||||
@@ -15,7 +15,6 @@ bell \- Ring a display's bell
|
||||
.SH SYNOPSIS
|
||||
\fBbell \fR?\fB\-displayof \fIwindow\fR? ?\fB\-nice\fR?
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
This command rings the bell on the display for \fIwindow\fR and
|
||||
@@ -28,6 +27,8 @@ may be modified with programs such as \fBxset\fR.
|
||||
If \fB\-nice\fR is not specified, this command also resets the screen saver
|
||||
for the screen. Some screen savers will ignore this, but others will reset
|
||||
so that the screen becomes visible again.
|
||||
|
||||
.SH KEYWORDS
|
||||
beep, bell, ring
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
45
doc/bind.n
45
doc/bind.n
@@ -19,9 +19,10 @@ bind \- Arrange for X events to invoke Tcl scripts
|
||||
.PP
|
||||
The \fBbind\fR command associates Tcl scripts with X events.
|
||||
If all three arguments are specified, \fBbind\fR will
|
||||
arrange for \fIscript\fR (a Tcl script) to be evaluated whenever
|
||||
the event(s) given by \fIsequence\fR occur in the window(s)
|
||||
identified by \fItag\fR.
|
||||
arrange for \fIscript\fR (a Tcl script called the
|
||||
.QW "binding script")
|
||||
to be evaluated whenever the event(s) given by \fIsequence\fR
|
||||
occur in the window(s) identified by \fItag\fR.
|
||||
If \fIscript\fR is prefixed with a
|
||||
.QW + ,
|
||||
then it is appended to
|
||||
@@ -151,7 +152,6 @@ requirement.
|
||||
The \fBCommand\fR and \fBOption\fR modifiers are equivalents of \fBMod1\fR
|
||||
resp. \fBMod2\fR, they correspond to Macintosh-specific modifier keys.
|
||||
.PP
|
||||
.VS 8.5
|
||||
The \fBExtended\fR modifier is, at present, specific to Windows. It
|
||||
appears on events that are associated with the keys on the
|
||||
.QW "extended keyboard" .
|
||||
@@ -160,7 +160,6 @@ and \fBControl\fR keys at the right of the keyboard, the cursor keys
|
||||
in the cluster to the left of the numeric pad, the \fBNumLock\fR key,
|
||||
the \fBBreak\fR key, the \fBPrintScreen\fR key, and the \fB/\fR and
|
||||
\fBEnter\fR keys in the numeric keypad.
|
||||
.VE 8.5
|
||||
.SS "EVENT TYPES"
|
||||
.PP
|
||||
The \fItype\fR field may be any of the standard X event types, with a
|
||||
@@ -207,9 +206,7 @@ always routed to the window that currently has focus. When the event
|
||||
is received you can use the \fB%D\fR substitution to get the
|
||||
\fIdelta\fR field for the event, which is a integer value describing how
|
||||
the mouse wheel has moved. The smallest value for which the
|
||||
system will report is defined by the OS. On Windows 95 & 98 machines
|
||||
this value is at least 120 before it is reported. However, higher
|
||||
resolution devices may be available in the future. The sign of the
|
||||
system will report is defined by the OS. The sign of the
|
||||
value determines which direction your widget should scroll. Positive
|
||||
values should scroll up and negative values should scroll down.
|
||||
.IP "\fBKeyPress\fR, \fBKeyRelease\fR" 5
|
||||
@@ -391,7 +388,8 @@ For example, \fB<Control\-comma>\fR is equivalent to
|
||||
\fB<Control\-KeyPress\-comma>\fR.
|
||||
.SH "BINDING SCRIPTS AND SUBSTITUTIONS"
|
||||
.PP
|
||||
The \fIscript\fR argument to \fBbind\fR is a Tcl script,
|
||||
The \fIscript\fR argument to \fBbind\fR is a Tcl script, called the
|
||||
.QW "binding script",
|
||||
which will be executed whenever the given event sequence occurs.
|
||||
\fICommand\fR will be executed in the same interpreter that the
|
||||
\fBbind\fR command was executed in, and it will run at global
|
||||
@@ -429,10 +427,7 @@ The \fIcount\fR field from the event. Valid only for \fBExpose\fR events.
|
||||
Indicates that there are \fIcount\fR pending \fBExpose\fR events which have not
|
||||
yet been delivered to the window.
|
||||
.IP \fB%d\fR 5
|
||||
The \fIdetail\fR
|
||||
.VS 8.5
|
||||
or \fIuser_data\fR
|
||||
.VE 8.5
|
||||
The \fIdetail\fR or \fIuser_data\fR
|
||||
field from the event. The \fB%d\fR is replaced by
|
||||
a string identifying the detail. For \fBEnter\fR,
|
||||
\fBLeave\fR, \fBFocusIn\fR, and \fBFocusOut\fR events,
|
||||
@@ -452,13 +447,11 @@ For \fBConfigureRequest\fR events, the string will be one of:
|
||||
\fBBelow\fR \fBNone\fR
|
||||
\fBBottomIf\fR \fBTopIf\fR
|
||||
.DE
|
||||
.VS 8.5
|
||||
For virtual events, the string will be whatever value is stored in the
|
||||
\fIuser_data\fR field when the event was created (typically with
|
||||
\fBevent generate\fR), or the empty string if the field is NULL.
|
||||
Virtual events corresponding to key sequence presses (see \fBevent
|
||||
add\fR for details) set the \fIuser_data\fR to NULL.
|
||||
.VE 8.5
|
||||
For events other than these, the substituted string is undefined.
|
||||
.RE
|
||||
.IP \fB%f\fR 5
|
||||
@@ -534,9 +527,7 @@ The \fIborder_width\fR field from the event. Valid only for
|
||||
.IP \fB%D\fR 5
|
||||
This reports the \fIdelta\fR value of a \fBMouseWheel\fR event. The
|
||||
\fIdelta\fR value represents the rotation units the mouse wheel has
|
||||
been moved. On Windows 95 & 98 systems the smallest value for the
|
||||
delta is 120. Future systems may support higher resolution values for
|
||||
the delta. The sign of the value represents the direction the mouse
|
||||
been moved. The sign of the value represents the direction the mouse
|
||||
wheel was scrolled.
|
||||
.IP \fB%E\fR 5
|
||||
The \fIsend_event\fR field from the event. Valid for all event types.
|
||||
@@ -617,13 +608,21 @@ the window.
|
||||
.PP
|
||||
The \fBcontinue\fR and \fBbreak\fR commands may be used inside a
|
||||
binding script to control the processing of matching scripts.
|
||||
If \fBcontinue\fR is invoked, then the current binding script
|
||||
is terminated but Tk will continue processing binding scripts
|
||||
associated with other \fItag\fR's.
|
||||
If \fBcontinue\fR is invoked within a binding script, then this
|
||||
binding script, including all other
|
||||
.QW +
|
||||
appended scripts, is terminated but Tk will continue processing
|
||||
binding scripts associated with other \fItag\fR's.
|
||||
If the \fBbreak\fR command is invoked within a binding script,
|
||||
then that script terminates and no other scripts will be invoked
|
||||
for the event.
|
||||
.PP
|
||||
Within a script called from the binding script, \fBreturn\fR
|
||||
\fB-code ok\fR may be used to continue processing (including
|
||||
.QW +
|
||||
appended scripts), or \fBreturn\fR \fB-code break\fR may be used to
|
||||
stop processing all other binding scripts.
|
||||
.PP
|
||||
If more than one binding matches a particular event and they
|
||||
have the same \fItag\fR, then the most specific binding
|
||||
is chosen and its script is evaluated.
|
||||
@@ -704,6 +703,7 @@ If an error occurs in executing the script for a binding then the
|
||||
The \fBbgerror\fR command will be executed at global level
|
||||
(outside the context of any Tcl procedure).
|
||||
.SH "EXAMPLES"
|
||||
.PP
|
||||
Arrange for a string describing the motion of the mouse to be printed
|
||||
out when the mouse is double-clicked:
|
||||
.CS
|
||||
@@ -725,3 +725,6 @@ pack [label .l \-textvariable keysym \-padx 2m \-pady 1m]
|
||||
bgerror(n), bindtags(n), event(n), focus(n), grab(n), keysyms(n)
|
||||
.SH KEYWORDS
|
||||
binding, event
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
@@ -14,7 +14,6 @@ bindtags \- Determine which bindings apply to a window, and order of evaluation
|
||||
.SH SYNOPSIS
|
||||
\fBbindtags \fIwindow \fR?\fItagList\fR?
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
When a binding is created with the \fBbind\fR command, it is
|
||||
@@ -73,6 +72,7 @@ associated with the \fBButton\fR tag, will no longer apply to \fB.b\fR,
|
||||
but any bindings associated with \fBTrickyButton\fR (perhaps some
|
||||
new button behavior) will apply.
|
||||
.SH EXAMPLE
|
||||
.PP
|
||||
If you have a set of nested \fBframe\fR widgets and you want events
|
||||
sent to a \fBbutton\fR widget to also be delivered to all the widgets
|
||||
up to the current \fBtoplevel\fR (in contrast to Tk's default
|
||||
@@ -93,9 +93,10 @@ proc setupBindtagsForTreeDelivery {widget} {
|
||||
\fBbindtags\fR $widget $tags
|
||||
}
|
||||
.CE
|
||||
|
||||
.SH "SEE ALSO"
|
||||
bind(n)
|
||||
|
||||
.SH KEYWORDS
|
||||
binding, event, tag
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
24
doc/bitmap.n
24
doc/bitmap.n
@@ -12,9 +12,13 @@
|
||||
.SH NAME
|
||||
bitmap \- Images that display two colors
|
||||
.SH SYNOPSIS
|
||||
.nf
|
||||
\fBimage create bitmap \fR?\fIname\fR? ?\fIoptions\fR?
|
||||
.BE
|
||||
|
||||
\fIimageName \fBcget\fR \fIoption\fR
|
||||
\fIimageName \fBconfigure\fR ?\fIoption\fR? ?\fIvalue option value ...\fR?
|
||||
.fi
|
||||
.BE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
A bitmap is an image whose pixels can display either of two colors
|
||||
@@ -30,7 +34,6 @@ producing a transparent effect.
|
||||
For other pixels, the image displays the foreground color if
|
||||
the source data is one and the background color if the source
|
||||
data is zero.
|
||||
|
||||
.SH "CREATING BITMAPS"
|
||||
.PP
|
||||
Like all images, bitmaps are created using the \fBimage create\fR
|
||||
@@ -38,6 +41,7 @@ command.
|
||||
Bitmaps support the following \fIoptions\fR:
|
||||
.TP
|
||||
\fB\-background \fIcolor\fR
|
||||
.
|
||||
Specifies a background color for the image in any of the standard
|
||||
ways accepted by Tk. If this option is set to an empty string
|
||||
then the background pixels will be transparent. This effect
|
||||
@@ -45,6 +49,7 @@ is achieved by using the source bitmap as the mask bitmap, ignoring
|
||||
any \fB\-maskdata\fR or \fB\-maskfile\fR options.
|
||||
.TP
|
||||
\fB\-data \fIstring\fR
|
||||
.
|
||||
Specifies the contents of the source bitmap as a string.
|
||||
The string must adhere to X11 bitmap format (e.g., as generated
|
||||
by the \fBbitmap\fR program).
|
||||
@@ -52,16 +57,19 @@ If both the \fB\-data\fR and \fB\-file\fR options are specified,
|
||||
the \fB\-data\fR option takes precedence.
|
||||
.TP
|
||||
\fB\-file \fIname\fR
|
||||
.
|
||||
\fIname\fR gives the name of a file whose contents define the
|
||||
source bitmap.
|
||||
The file must adhere to X11 bitmap format (e.g., as generated
|
||||
by the \fBbitmap\fR program).
|
||||
.TP
|
||||
\fB\-foreground \fIcolor\fR
|
||||
.
|
||||
Specifies a foreground color for the image in any of the standard
|
||||
ways accepted by Tk.
|
||||
.TP
|
||||
\fB\-maskdata \fIstring\fR
|
||||
.
|
||||
Specifies the contents of the mask as a string.
|
||||
The string must adhere to X11 bitmap format (e.g., as generated
|
||||
by the \fBbitmap\fR program).
|
||||
@@ -69,11 +77,11 @@ If both the \fB\-maskdata\fR and \fB\-maskfile\fR options are specified,
|
||||
the \fB\-maskdata\fR option takes precedence.
|
||||
.TP
|
||||
\fB\-maskfile \fIname\fR
|
||||
.
|
||||
\fIname\fR gives the name of a file whose contents define the
|
||||
mask.
|
||||
The file must adhere to X11 bitmap format (e.g., as generated
|
||||
by the \fBbitmap\fR program).
|
||||
|
||||
.SH "IMAGE COMMAND"
|
||||
.PP
|
||||
When a bitmap image is created, Tk also creates a new command
|
||||
@@ -89,12 +97,14 @@ determine the exact behavior of the command. The following
|
||||
commands are possible for bitmap images:
|
||||
.TP
|
||||
\fIimageName \fBcget\fR \fIoption\fR
|
||||
.
|
||||
Returns the current value of the configuration option given
|
||||
by \fIoption\fR.
|
||||
\fIOption\fR may have any of the values accepted by the
|
||||
\fBimage create bitmap\fR command.
|
||||
\fBimage create\fR \fBbitmap\fR command.
|
||||
.TP
|
||||
\fIimageName \fBconfigure\fR ?\fIoption\fR? ?\fIvalue option value ...\fR?
|
||||
.
|
||||
Query or modify the configuration options for the image.
|
||||
If no \fIoption\fR is specified, returns a list describing all of
|
||||
the available options for \fIimageName\fR (see \fBTk_ConfigureInfo\fR for
|
||||
@@ -106,7 +116,9 @@ one or more \fIoption\-value\fR pairs are specified, then the command
|
||||
modifies the given option(s) to have the given value(s); in
|
||||
this case the command returns an empty string.
|
||||
\fIOption\fR may have any of the values accepted by the
|
||||
\fBimage create bitmap\fR command.
|
||||
|
||||
\fBimage create\fR \fBbitmap\fR command.
|
||||
.SH KEYWORDS
|
||||
bitmap, image
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
275
doc/busy.n
Normal file
275
doc/busy.n
Normal file
@@ -0,0 +1,275 @@
|
||||
'\"
|
||||
'\" Copyright (c) 1993-1998 Lucent Technologies, Inc.
|
||||
'\" Copyright (c) 2008 Jos Decoster
|
||||
'\"
|
||||
'\" Permission to use, copy, modify, and distribute this software and its
|
||||
'\" documentation for any purpose and without fee is hereby granted, provided
|
||||
'\" that the above copyright notice appear in all copies and that both that
|
||||
'\" the copyright notice and warranty disclaimer appear in supporting
|
||||
'\" documentation, and that the names of Lucent Technologies any of their
|
||||
'\" entities not be used in advertising or publicity pertaining to
|
||||
'\" distribution of the software without specific, written prior permission.
|
||||
'\"
|
||||
'\" Lucent Technologies disclaims all warranties with regard to this software,
|
||||
'\" including all implied warranties of merchantability and fitness. In no
|
||||
'\" event shall Lucent Technologies be liable for any special, indirect or
|
||||
'\" consequential damages or any damages whatsoever resulting from loss of
|
||||
'\" use, data or profits, whether in an action of contract, negligence or
|
||||
'\" other tortuous action, arising out of or in connection with the use or
|
||||
'\" performance of this software.
|
||||
'\"
|
||||
'\" BLT::busy command created by George Howlett.
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
.TH busy n "" Tk "Tk Built-In Commands"
|
||||
.so man.macros
|
||||
.BS
|
||||
'\" Note: do not modify the .SH NAME line immediately below!
|
||||
.SH NAME
|
||||
busy \- confine pointer events to a window sub-tree
|
||||
.SH SYNOPSIS
|
||||
\fBtk busy\fR \fIwindow \fR?\fIoptions\fR?
|
||||
.sp
|
||||
\fBtk busy hold\fR \fIwindow \fR?\fIoptions\fR?
|
||||
.sp
|
||||
\fBtk busy configure \fIwindow\fR ?\fIoption value\fR?...
|
||||
.sp
|
||||
\fBtk busy forget\fR \fIwindow \fR?\fIwindow \fR?...
|
||||
.sp
|
||||
\fBtk busy current\fR ?\fIpattern\fR?
|
||||
.sp
|
||||
\fBtk busy status \fIwindow\fR
|
||||
.BE
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \fBtk busy\fR command provides a simple means to block pointer events from
|
||||
Tk widgets, while overriding the widget's cursor with a configurable busy
|
||||
cursor. Note this command does not prevent keyboard events from being sent to
|
||||
the widgets made busy.
|
||||
.SH INTRODUCTION
|
||||
.PP
|
||||
There are many times in applications where you want to temporarily restrict
|
||||
what actions the user can take. For example, an application could have a
|
||||
.QW Run
|
||||
button that when pressed causes some processing to occur. However, while the
|
||||
application is busy processing, you probably don't want the user to be
|
||||
able to click the
|
||||
.QW Run
|
||||
button again. You may also want restrict the user from other tasks such as
|
||||
clicking a
|
||||
.QW Print
|
||||
button.
|
||||
.PP
|
||||
The \fBtk busy\fR command lets you make Tk widgets busy. This means that user
|
||||
interactions such as button clicks, moving the mouse, typing at the keyboard,
|
||||
etc.\0are ignored by the widget. You can set a special cursor (like a watch)
|
||||
that overrides the widget's normal cursor, providing feedback that the
|
||||
application (widget) is temporarily busy.
|
||||
.PP
|
||||
When a widget is made busy, the widget and all of its descendants will ignore
|
||||
pointer events. It's easy to make an entire panel of widgets busy. You can
|
||||
simply make the toplevel widget (such as
|
||||
.QW . )
|
||||
busy. This is easier and far much more efficient than recursively traversing
|
||||
the widget hierarchy, disabling each widget and re-configuring its cursor.
|
||||
.PP
|
||||
Often, the \fBtk busy\fR command can be used instead of Tk's \fBgrab\fR
|
||||
command. Unlike \fBgrab\fR which restricts all user interactions to one
|
||||
widget, with the \fBtk busy\fR command you can have more than one widget
|
||||
active (for example, a
|
||||
.QW Cancel
|
||||
dialog and a
|
||||
.QW Help
|
||||
button).
|
||||
.SS EXAMPLE
|
||||
.PP
|
||||
You can make several widgets busy by simply making its ancestor widget busy
|
||||
using the \fBhold\fR operation.
|
||||
.PP
|
||||
.CS
|
||||
frame .top
|
||||
button .top.button; canvas .top.canvas
|
||||
pack .top.button .top.canvas
|
||||
pack .top
|
||||
# . . .
|
||||
\fBtk busy\fR hold .top
|
||||
update
|
||||
.CE
|
||||
.PP
|
||||
All the widgets within \fB.top\fR (including \fB.top\fR) are now busy. Using
|
||||
\fBupdate\fR insures that \fBtk busy\fR command will take effect before any
|
||||
other user events can occur.
|
||||
.PP
|
||||
When the application is no longer busy processing, you can allow user
|
||||
interactions again and free any resources it allocated by the \fBforget\fR
|
||||
operation.
|
||||
.PP
|
||||
.CS
|
||||
\fBtk busy\fR forget .top
|
||||
.CE
|
||||
.PP
|
||||
The busy window has a configurable cursor. You can change the busy cursor
|
||||
using the \fBconfigure\fR operation.
|
||||
.PP
|
||||
.CS
|
||||
\fBtk busy\fR configure .top \-cursor "watch"
|
||||
.CE
|
||||
.PP
|
||||
Destroying the widget will also clean up any resources allocated by the \fBtk
|
||||
busy\fR command.
|
||||
.PP
|
||||
.SH OPERATIONS
|
||||
.PP
|
||||
The following operations are available for the \fBtk busy\fR command:
|
||||
.TP
|
||||
\fBtk busy \fIwindow\fR ?\fIoption value\fR?...
|
||||
.
|
||||
Shortcut for \fBtk busy hold\fR command.
|
||||
.TP
|
||||
\fBtk busy hold \fIwindow\fR ?\fIoption value\fR?...
|
||||
.
|
||||
Makes the specified \fIwindow\fR (and its descendants in the Tk window
|
||||
hierarchy) appear busy. \fIWindow\fR must be a valid path name of a Tk widget.
|
||||
A transparent window is put in front of the specified window. This transparent
|
||||
window is mapped the next time idle tasks are processed, and the specified
|
||||
window and its descendants will be blocked from user interactions. Normally
|
||||
\fBupdate\fR should be called immediately afterward to insure that the hold
|
||||
operation is in effect before the application starts its processing. The
|
||||
following configuration options are valid:
|
||||
.RS
|
||||
.TP
|
||||
\fB\-cursor \fIcursorName\fR
|
||||
.
|
||||
Specifies the cursor to be displayed when the widget is made busy.
|
||||
\fICursorName\fR can be in any form accepted by \fBTk_GetCursor\fR. The
|
||||
default cursor is \fBwait\fR on Windows and \fBwatch\fR on other platforms.
|
||||
.RE
|
||||
.TP
|
||||
\fBtk busy cget \fIwindow\fR \fIoption\fR
|
||||
.
|
||||
Queries the \fBtk busy\fR command configuration options for \fIwindow\fR.
|
||||
\fIWindow\fR must be the path name of a widget previously made busy by the
|
||||
\fBhold\fR operation. The command returns the present value of the specified
|
||||
\fIoption\fR. \fIOption\fR may have any of the values accepted by the
|
||||
\fBhold\fR operation.
|
||||
.TP
|
||||
\fBtk busy configure \fIwindow\fR ?\fIoption value\fR?...
|
||||
.
|
||||
Queries or modifies the \fBtk busy\fR command configuration options for
|
||||
\fIwindow\fR. \fIWindow\fR must be the path name of a widget previously made
|
||||
busy by the \fBhold\fR operation. If no options are specified, a list
|
||||
describing all of the available options for \fIwindow\fR (see
|
||||
\fBTk_ConfigureInfo\fR for information on the format of this list) is
|
||||
returned. If \fIoption\fR is specified with no \fIvalue\fR, then the command
|
||||
returns a list describing the one named option (this list will be identical to
|
||||
the corresponding sublist of the value returned if no \fIoption\fR is
|
||||
specified). If one or more \fIoption\-value\fR pairs are specified, then the
|
||||
command modifies the given widget option(s) to have the given value(s); in
|
||||
this case the command returns the empty string. \fIOption\fR may have any of
|
||||
the values accepted by the \fBhold\fR operation.
|
||||
.RS
|
||||
.PP
|
||||
Please note that the option database is referenced through \fIwindow\fR. For
|
||||
example, if the widget \fB.frame\fR is to be made busy, the busy cursor can be
|
||||
specified for it by either \fBoption\fR command:
|
||||
.PP
|
||||
.CS
|
||||
option add *frame.busyCursor gumby
|
||||
option add *Frame.BusyCursor gumby
|
||||
.CE
|
||||
.RE
|
||||
.TP
|
||||
\fBtk busy forget \fIwindow\fR ?\fIwindow\fR?...
|
||||
.
|
||||
Releases resources allocated by the \fBtk busy\fR command for \fIwindow\fR,
|
||||
including the transparent window. User events will again be received by
|
||||
\fIwindow\fR. Resources are also released when \fIwindow\fR is destroyed.
|
||||
\fIWindow\fR must be the name of a widget specified in the \fBhold\fR
|
||||
operation, otherwise an error is reported.
|
||||
.TP
|
||||
\fBtk busy current \fR?\fIpattern\fR?
|
||||
.
|
||||
Returns the pathnames of all widgets that are currently busy. If a
|
||||
\fIpattern\fR is given, only the path names of busy widgets matching
|
||||
\fIpattern\fR are returned.
|
||||
.TP
|
||||
\fBtk busy status \fIwindow\fR
|
||||
.
|
||||
Returns the status of a widget \fIwindow\fR. If \fIwindow\fR presently can not
|
||||
receive user interactions, \fB1\fR is returned, otherwise \fB0\fR.
|
||||
.SH "EVENT HANDLING"
|
||||
.SS BINDINGS
|
||||
.PP
|
||||
The event blocking feature is implemented by creating and mapping a
|
||||
transparent window that completely covers the widget. When the busy window is
|
||||
mapped, it invisibly shields the widget and its hierarchy from all events that
|
||||
may be sent. Like Tk widgets, busy windows have widget names in the Tk window
|
||||
hierarchy. This means that you can use the \fBbind\fR command, to handle
|
||||
events in the busy window.
|
||||
.PP
|
||||
.CS
|
||||
\fBtk busy\fR hold .frame.canvas
|
||||
bind .frame.canvas_Busy <Enter> { ... }
|
||||
.CE
|
||||
.PP
|
||||
Normally the busy window is a sibling of the widget. The name of the busy
|
||||
window is
|
||||
.QW \fIwidget\fB_Busy\fR
|
||||
where \fIwidget\fR is the name of the widget to be made busy. In the previous
|
||||
example, the pathname of the busy window is
|
||||
.QW \fB.frame.canvas_Busy\fR .
|
||||
The exception is when the widget is a toplevel widget (such as
|
||||
.QW . )
|
||||
where the busy window can't be made a sibling. The busy window is then a child
|
||||
of the widget named
|
||||
.QW \fIwidget\fB._Busy\fR
|
||||
where \fIwidget\fR is the name of the toplevel widget. In the following
|
||||
example, the pathname of the busy window is
|
||||
.QW \fB._Busy\fR .
|
||||
.PP
|
||||
.CS
|
||||
\fBtk busy\fR hold .
|
||||
bind ._Busy <Enter> { ... }
|
||||
.CE
|
||||
.SS "ENTER/LEAVE EVENTS"
|
||||
.PP
|
||||
Mapping and unmapping busy windows generates Enter/Leave events for all
|
||||
widgets they cover. Please note this if you are tracking Enter/Leave events in
|
||||
widgets.
|
||||
.SS "KEYBOARD EVENTS"
|
||||
.PP
|
||||
When a widget is made busy, the widget is prevented from gaining the keyboard
|
||||
focus by a user clicking on it by the busy window. But if the widget already had
|
||||
focus, it still may receive keyboard events. The widget can also still receive
|
||||
focus through keyboard traversal. To prevent this, you must move
|
||||
focus to another window and make sure the focus can not go back to the widgets
|
||||
made busy (e.g. but restricting focus to a cancel button).
|
||||
.PP
|
||||
.CS
|
||||
pack [frame .frame]
|
||||
pack [text .frame.text]
|
||||
\fBtk busy\fR hold .frame
|
||||
pack [button .cancel -text "Cancel" -command exit]
|
||||
focus .cancel
|
||||
bind .cancel <Tab> {break}
|
||||
bind .cancel <Shift-Tab> {break}
|
||||
update
|
||||
.CE
|
||||
.PP
|
||||
The above example moves the focus from .frame immediately after invoking the
|
||||
\fBhold\fR so that no keyboard events will be sent to \fB.frame\fR or any of
|
||||
its descendants. It also makes sure it's not possible to leave button
|
||||
\fB.cancel\fR using the keyboard.
|
||||
.SH PORTABILITY
|
||||
.PP
|
||||
Note that the \fBtk busy\fR command does not currently have any effect on OSX
|
||||
when Tk is built using Aqua support.
|
||||
.SH "SEE ALSO"
|
||||
grab(n)
|
||||
.SH KEYWORDS
|
||||
busy, keyboard events, pointer events, window
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
58
doc/button.n
58
doc/button.n
@@ -4,13 +4,13 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH button n 4.4 Tk "Tk Built-In Commands"
|
||||
.so man.macros
|
||||
.BS
|
||||
'\" Note: do not modify the .SH NAME line immediately below!
|
||||
.SH NAME
|
||||
button \- Create and manipulate button widgets
|
||||
button \- Create and manipulate 'button' action widgets
|
||||
.SH SYNOPSIS
|
||||
\fBbutton\fR \fIpathName \fR?\fIoptions\fR?
|
||||
.SO
|
||||
@@ -57,25 +57,24 @@ The empty string is the default value.
|
||||
.OP \-state state State
|
||||
Specifies one of three states for the button: \fBnormal\fR, \fBactive\fR,
|
||||
or \fBdisabled\fR. In normal state the button is displayed using the
|
||||
\fBforeground\fR and \fBbackground\fR options. The active state is
|
||||
\fB\-foreground\fR and \fB\-background\fR options. The active state is
|
||||
typically used when the pointer is over the button. In active state
|
||||
the button is displayed using the \fBactiveForeground\fR and
|
||||
\fBactiveBackground\fR options. Disabled state means that the button
|
||||
the button is displayed using the \fB\-activeforeground\fR and
|
||||
\fB\-activebackground\fR options. Disabled state means that the button
|
||||
should be insensitive: the default bindings will refuse to activate
|
||||
the widget and will ignore mouse button presses.
|
||||
In this state the \fBdisabledForeground\fR and
|
||||
\fBbackground\fR options determine how the button is displayed.
|
||||
In this state the \fB\-disabledforeground\fR and
|
||||
\fB\-background\fR options determine how the button is displayed.
|
||||
.OP \-width width Width
|
||||
Specifies a desired width for the button.
|
||||
If an image or bitmap is being displayed in the button then the value is in
|
||||
screen units (i.e. any of the forms acceptable to \fBTk_GetPixels\fR).
|
||||
For a text button (no image or with \fB\-compound none\fR) then the width
|
||||
For a text button (no image or with \fB\-compound none\fR) then the width
|
||||
specifies how much space in characters to allocate for the text label.
|
||||
If the width is negative then this specifies a minimum width.
|
||||
If this option is not specified, the button's desired width is computed
|
||||
from the size of the image or bitmap or text being displayed in it.
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The \fBbutton\fR command creates a new window (given by the
|
||||
@@ -92,18 +91,17 @@ there must not exist a window named \fIpathName\fR, but
|
||||
A button is a widget that displays a textual string, bitmap or image.
|
||||
If text is displayed, it must all be in a single font, but it
|
||||
can occupy multiple lines on the screen (if it contains newlines
|
||||
or if wrapping occurs because of the \fBwrapLength\fR option) and
|
||||
or if wrapping occurs because of the \fB\-wraplength\fR option) and
|
||||
one of the characters may optionally be underlined using the
|
||||
\fBunderline\fR option.
|
||||
\fB\-underline\fR option.
|
||||
It can display itself in either of three different ways, according
|
||||
to
|
||||
the \fBstate\fR option;
|
||||
the \fB\-state\fR option;
|
||||
it can be made to appear raised, sunken, or flat;
|
||||
and it can be made to flash. When a user invokes the
|
||||
button (by pressing mouse button 1 with the cursor over the
|
||||
button), then the Tcl command specified in the \fB\-command\fR
|
||||
option is invoked.
|
||||
|
||||
.SH "WIDGET COMMAND"
|
||||
.PP
|
||||
The \fBbutton\fR command creates a new Tcl command whose
|
||||
@@ -139,9 +137,9 @@ command.
|
||||
.TP
|
||||
\fIpathName \fBflash\fR
|
||||
Flash the button. This is accomplished by redisplaying the button
|
||||
several times, alternating between active and normal colors. At
|
||||
the end of the flash the button is left in the same normal/active
|
||||
state as when the command was invoked.
|
||||
several times, alternating between the configured activebackground
|
||||
and background colors. At the end of the flash the button is left
|
||||
in the same normal/active state as when the command was invoked.
|
||||
This command is ignored if the button's state is \fBdisabled\fR.
|
||||
.TP
|
||||
\fIpathName \fBinvoke\fR
|
||||
@@ -149,7 +147,6 @@ Invoke the Tcl command associated with the button, if there is one.
|
||||
The return value is the return value from the Tcl command, or an
|
||||
empty string if there is no command associated with the button.
|
||||
This command is ignored if the button's state is \fBdisabled\fR.
|
||||
|
||||
.SH "DEFAULT BINDINGS"
|
||||
.PP
|
||||
Tk automatically creates class bindings for buttons that give them
|
||||
@@ -176,27 +173,38 @@ actions occur: the button is completely non-responsive.
|
||||
.PP
|
||||
The behavior of buttons can be changed by defining new bindings for
|
||||
individual widgets or by redefining the class bindings.
|
||||
|
||||
.SH "PLATFORM NOTES"
|
||||
.PP
|
||||
On Aqua/Mac OS X, some configuration options are ignored for the purpose of
|
||||
drawing of the widget because they would otherwise conflict with platform
|
||||
guidelines. The \fBconfigure\fR and \fBcget\fR subcommands can still
|
||||
manipulate the values, but do not cause any variation to the look of the
|
||||
widget. The options affected notably include \fB\-background\fR and
|
||||
\fB\-relief\fR.
|
||||
.SH EXAMPLES
|
||||
.PP
|
||||
This is the classic Tk
|
||||
.QW "Hello, World!"
|
||||
demonstration:
|
||||
.PP
|
||||
.CS
|
||||
\fBbutton\fR .b \-text "Hello, World!" \-command exit
|
||||
pack .b
|
||||
\fBbutton\fR .b \-text "Hello, World!" \-command exit
|
||||
pack .b
|
||||
.CE
|
||||
.PP
|
||||
This example demonstrates how to handle button accelerators:
|
||||
.PP
|
||||
.CS
|
||||
\fBbutton\fR .b1 \-text Hello \-underline 0
|
||||
\fBbutton\fR .b2 \-text World \-underline 0
|
||||
bind . <Key\-h> {.b1 flash; .b1 invoke}
|
||||
bind . <Key\-w> {.b2 flash; .b2 invoke}
|
||||
pack .b1 .b2
|
||||
\fBbutton\fR .b1 \-text Hello \-underline 0
|
||||
\fBbutton\fR .b2 \-text World \-underline 0
|
||||
bind . <Key\-h> {.b1 flash; .b1 invoke}
|
||||
bind . <Key\-w> {.b2 flash; .b2 invoke}
|
||||
pack .b1 .b2
|
||||
.CE
|
||||
.SH "SEE ALSO"
|
||||
ttk::button(n)
|
||||
.SH KEYWORDS
|
||||
button, widget
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
822
doc/canvas.n
822
doc/canvas.n
File diff suppressed because it is too large
Load Diff
@@ -4,13 +4,13 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH checkbutton n 4.4 Tk "Tk Built-In Commands"
|
||||
.so man.macros
|
||||
.BS
|
||||
'\" Note: do not modify the .SH NAME line immediately below!
|
||||
.SH NAME
|
||||
checkbutton \- Create and manipulate checkbutton widgets
|
||||
checkbutton \- Create and manipulate 'checkbutton' boolean selection widgets
|
||||
.SH SYNOPSIS
|
||||
\fBcheckbutton\fI pathName \fR?\fIoptions\fR?
|
||||
.SO
|
||||
@@ -38,7 +38,7 @@ If this option is not specified, the button's desired height is computed
|
||||
from the size of the image or bitmap or text being displayed in it.
|
||||
.OP \-indicatoron indicatorOn IndicatorOn
|
||||
Specifies whether or not the indicator should be drawn. Must be a
|
||||
proper boolean value. If false, the \fBrelief\fR option is
|
||||
proper boolean value. If false, the \fB\-relief\fR option is
|
||||
ignored and the widget's relief is always sunken if the widget is
|
||||
selected and raised otherwise.
|
||||
.OP \-offrelief offRelief OffRelief
|
||||
@@ -52,7 +52,7 @@ and setting \fB\-indicatoron\fR to false and \fB\-overrelief\fR to
|
||||
the effect is achieved
|
||||
of having a flat button that raises on mouse-over and which is
|
||||
depressed when activated. This is the behavior typically exhibited by
|
||||
the Bold, Italic, and Underline checkbuttons on the toolbar of a
|
||||
the Bold, Italic, and Underline checkbuttons on the toolbar of a
|
||||
word-processor, for example.
|
||||
.OP \-offvalue offValue Value
|
||||
Specifies value to store in the button's associated variable whenever
|
||||
@@ -79,34 +79,30 @@ whenever the widget is selected.
|
||||
If specified as an empty string then no special color is used for
|
||||
displaying when the widget is selected.
|
||||
.OP \-selectimage selectImage SelectImage
|
||||
Specifies an image to display (in place of the \fBimage\fR option)
|
||||
Specifies an image to display (in place of the \fB\-image\fR option)
|
||||
when the checkbutton is selected.
|
||||
This option is ignored unless the \fBimage\fR option has been
|
||||
This option is ignored unless the \fB\-image\fR option has been
|
||||
specified.
|
||||
.OP \-state state State
|
||||
Specifies one of three states for the checkbutton: \fBnormal\fR, \fBactive\fR,
|
||||
or \fBdisabled\fR. In normal state the checkbutton is displayed using the
|
||||
\fBforeground\fR and \fBbackground\fR options. The active state is
|
||||
\fB\-foreground\fR and \fB\-background\fR options. The active state is
|
||||
typically used when the pointer is over the checkbutton. In active state
|
||||
the checkbutton is displayed using the \fBactiveForeground\fR and
|
||||
\fBactiveBackground\fR options. Disabled state means that the checkbutton
|
||||
the checkbutton is displayed using the \fB\-activeforeground\fR and
|
||||
\fB\-activebackground\fR options. Disabled state means that the checkbutton
|
||||
should be insensitive: the default bindings will refuse to activate
|
||||
the widget and will ignore mouse button presses.
|
||||
In this state the \fBdisabledForeground\fR and
|
||||
\fBbackground\fR options determine how the checkbutton is displayed.
|
||||
In this state the \fB\-disabledforeground\fR and
|
||||
\fB\-background\fR options determine how the checkbutton is displayed.
|
||||
.OP \-tristateimage tristateImage TristateImage
|
||||
.VS 8.5
|
||||
Specifies an image to display (in place of the \fBimage\fR option)
|
||||
Specifies an image to display (in place of the \fB\-image\fR option)
|
||||
when the checkbutton is in tri-state mode.
|
||||
This option is ignored unless the \fBimage\fR option has been
|
||||
This option is ignored unless the \fB\-image\fR option has been
|
||||
specified.
|
||||
.VE 8.5
|
||||
.OP \-tristatevalue tristateValue Value
|
||||
.VS 8.5
|
||||
Specifies the value that causes the checkbutton to display the multi-value
|
||||
Specifies the value that causes the checkbutton to display the multi-value
|
||||
selection, also known as the tri-state mode. Defaults to
|
||||
.QW "" .
|
||||
.VE 8.5
|
||||
.OP \-variable variable Variable
|
||||
Specifies the name of a global variable to set to indicate whether
|
||||
or not this button is selected. Defaults to the name of the
|
||||
@@ -138,13 +134,13 @@ that displays a textual string, bitmap or image
|
||||
and a square called an \fIindicator\fR.
|
||||
If text is displayed, it must all be in a single font, but it
|
||||
can occupy multiple lines on the screen (if it contains newlines
|
||||
or if wrapping occurs because of the \fBwrapLength\fR option) and
|
||||
or if wrapping occurs because of the \fB\-wraplength\fR option) and
|
||||
one of the characters may optionally be underlined using the
|
||||
\fBunderline\fR option.
|
||||
\fB\-underline\fR option.
|
||||
A checkbutton has
|
||||
all of the behavior of a simple button, including the
|
||||
following: it can display itself in either of three different
|
||||
ways, according to the \fBstate\fR option;
|
||||
ways, according to the \fB\-state\fR option;
|
||||
it can be made to appear
|
||||
raised, sunken, or flat; it can be made to flash; and it invokes
|
||||
a Tcl command whenever mouse button 1 is clicked over the
|
||||
@@ -155,17 +151,16 @@ If a checkbutton is selected then the indicator is normally
|
||||
drawn with a selected appearance, and
|
||||
a Tcl variable associated with the checkbutton is set to a particular
|
||||
value (normally 1).
|
||||
.VS 8.5
|
||||
The indicator is drawn with a check mark inside.
|
||||
If the checkbutton is not selected, then the indicator is drawn with a
|
||||
deselected appearance, and the associated variable is
|
||||
set to a different value (typically 0).
|
||||
The indicator is drawn without a check mark inside. In the special case
|
||||
where the variable (if specified) has a value that matches the tristatevalue,
|
||||
the indicator is drawn with a tri-state appearance and is in the tri-state
|
||||
mode indicating mixed or multiple values. (This is used when the check
|
||||
The indicator is drawn without a check mark inside. In the special case
|
||||
where the variable (if specified) has a value that matches the tristatevalue,
|
||||
the indicator is drawn with a tri-state appearance and is in the tri-state
|
||||
mode indicating mixed or multiple values. (This is used when the check
|
||||
box represents the state of multiple items.)
|
||||
The indicator is drawn in a platform dependent manner. Under Unix and
|
||||
The indicator is drawn in a platform dependent manner. Under Unix and
|
||||
Windows, the background interior of the box is
|
||||
.QW grayed .
|
||||
Under Mac, the indicator is drawn with a dash mark inside.
|
||||
@@ -190,7 +185,6 @@ changes to and from the button's
|
||||
and
|
||||
.QW tristate
|
||||
values.
|
||||
.VE 8.5
|
||||
.SH "WIDGET COMMAND"
|
||||
.PP
|
||||
The \fBcheckbutton\fR command creates a new Tcl command whose
|
||||
@@ -270,7 +264,8 @@ invoked, if there is one).
|
||||
.IP [3]
|
||||
When a checkbutton has the input focus, the space key causes the checkbutton
|
||||
to be invoked. Under Windows, there are additional key bindings; plus
|
||||
(+) and equal (=) select the button, and minus (\-) deselects the button.
|
||||
(\fB+\fR) and equal (\fB=\fR) select the button, and minus (\fB\-\fR)
|
||||
deselects the button.
|
||||
.PP
|
||||
If the checkbutton's state is \fBdisabled\fR then none of the above
|
||||
actions occur: the checkbutton is completely non-responsive.
|
||||
@@ -278,17 +273,21 @@ actions occur: the checkbutton is completely non-responsive.
|
||||
The behavior of checkbuttons can be changed by defining new bindings for
|
||||
individual widgets or by redefining the class bindings.
|
||||
.SH EXAMPLE
|
||||
.PP
|
||||
This example shows a group of uncoupled checkbuttons.
|
||||
.PP
|
||||
.CS
|
||||
labelframe .lbl \-text "Steps:"
|
||||
\fBcheckbutton\fR .c1 \-text Lights \-variable lights
|
||||
\fBcheckbutton\fR .c2 \-text Cameras \-variable cameras
|
||||
\fBcheckbutton\fR .c3 \-text Action! \-variable action
|
||||
pack .c1 .c2 .c3 \-in .lbl
|
||||
pack .lbl
|
||||
labelframe .lbl \-text "Steps:"
|
||||
\fBcheckbutton\fR .c1 \-text Lights \-variable lights
|
||||
\fBcheckbutton\fR .c2 \-text Cameras \-variable cameras
|
||||
\fBcheckbutton\fR .c3 \-text Action! \-variable action
|
||||
pack .c1 .c2 .c3 \-in .lbl
|
||||
pack .lbl
|
||||
.CE
|
||||
.SH "SEE ALSO"
|
||||
button(n), options(n), radiobutton(n), ttk::checkbutton(n)
|
||||
.SH KEYWORDS
|
||||
checkbutton, widget
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
@@ -13,7 +13,6 @@ tk_chooseColor \- pops up a dialog box for the user to select a color.
|
||||
.SH SYNOPSIS
|
||||
\fBtk_chooseColor \fR?\fIoption value ...\fR?
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
The procedure \fBtk_chooseColor\fR pops up a dialog box for the
|
||||
@@ -38,9 +37,12 @@ name of the color in a form acceptable to \fBTk_GetColor\fR. If the
|
||||
user cancels the operation, both commands will return the empty
|
||||
string.
|
||||
.SH EXAMPLE
|
||||
.PP
|
||||
.CS
|
||||
button .b \-bg [tk_chooseColor \-initialcolor gray \-title "Choose color"]
|
||||
.CE
|
||||
|
||||
.SH KEYWORDS
|
||||
color selection dialog
|
||||
color, color selection, dialog
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
'\"
|
||||
'\" Copyright (c) 1998-2000 by Scriptics Corporation.
|
||||
'\" All rights reserved.
|
||||
'\"
|
||||
'\"
|
||||
.TH tk_chooseDirectory n 8.3 Tk "Tk Built-In Commands"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -19,8 +19,11 @@ possible as command line arguments:
|
||||
.TP
|
||||
\fB\-initialdir\fR \fIdirname\fR
|
||||
Specifies that the directories in \fIdirectory\fR should be displayed
|
||||
when the dialog pops up. If this parameter is not specified, then
|
||||
the directories in the current working directory are displayed. If the
|
||||
when the dialog pops up. If this parameter is not specified,
|
||||
the initial directory defaults to the current working directory
|
||||
on non-Windows systems and on Windows systems prior to Vista.
|
||||
On Vista and later systems, the initial directory defaults to the last
|
||||
user-selected directory for the application. If the
|
||||
parameter specifies a relative path, the return value will convert the
|
||||
relative path to an absolute path.
|
||||
.TP
|
||||
@@ -38,6 +41,7 @@ turns the file dialog into a sheet attached to the parent window.
|
||||
Specifies a string to display as the title of the dialog box. If this
|
||||
option is not specified, then a default title will be displayed.
|
||||
.SH EXAMPLE
|
||||
.PP
|
||||
.CS
|
||||
set dir [\fBtk_chooseDirectory\fR \e
|
||||
\-initialdir ~ \-title "Choose a directory"]
|
||||
@@ -47,8 +51,10 @@ if {$dir eq ""} {
|
||||
label .l \-text "Selected $dir"
|
||||
}
|
||||
.CE
|
||||
|
||||
.SH "SEE ALSO"
|
||||
tk_getOpenFile(n), tk_getSaveFile(n)
|
||||
.SH KEYWORDS
|
||||
directory, selection, dialog, platform-specific
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
'\"
|
||||
'\" See the file "license.terms" for information on usage and redistribution
|
||||
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
'\"
|
||||
'\"
|
||||
.TH clipboard n 8.4 Tk "Tk Built-In Commands"
|
||||
.so man.macros
|
||||
.BS
|
||||
@@ -14,11 +14,10 @@ clipboard \- Manipulate Tk clipboard
|
||||
.SH SYNOPSIS
|
||||
\fBclipboard \fIoption\fR ?\fIarg arg ...\fR?
|
||||
.BE
|
||||
|
||||
.SH DESCRIPTION
|
||||
.PP
|
||||
This command provides a Tcl interface to the Tk clipboard,
|
||||
which stores data for later retrieval using the selection mechanism
|
||||
which stores data for later retrieval using the selection mechanism
|
||||
(via the \fB\-selection CLIPBOARD\fR option).
|
||||
In order to copy data into the clipboard, \fBclipboard clear\fR must
|
||||
be called, followed by a sequence of one or more calls to \fBclipboard
|
||||
@@ -28,15 +27,9 @@ appends should be completed before returning to the event loop.
|
||||
The first argument to \fBclipboard\fR determines the format of the
|
||||
rest of the arguments and the behavior of the command. The following
|
||||
forms are currently supported:
|
||||
.PP
|
||||
.TP
|
||||
\fBclipboard clear\fR ?\fB\-displayof\fR \fIwindow\fR?
|
||||
Claims ownership of the clipboard on \fIwindow\fR's display and removes
|
||||
any previous contents. \fIWindow\fR defaults to
|
||||
.QW . .
|
||||
Returns an empty string.
|
||||
.TP
|
||||
\fBclipboard append\fR ?\fB\-displayof\fR \fIwindow\fR? ?\fB\-format\fR \fIformat\fR? ?\fB\-type\fR \fItype\fR? ?\fB\-\|\-\fR? \fIdata\fR
|
||||
.
|
||||
Appends \fIdata\fR to the clipboard on \fIwindow\fR's
|
||||
display in the form given by \fItype\fR with the representation given
|
||||
by \fIformat\fR and claims ownership of the clipboard on \fIwindow\fR's
|
||||
@@ -47,19 +40,19 @@ display.
|
||||
(the desired
|
||||
.QW target
|
||||
for conversion, in ICCCM terminology), and
|
||||
should be an atom name such as STRING or FILE_NAME; see the
|
||||
should be an atom name such as \fBSTRING\fR or \fBFILE_NAME\fR; see the
|
||||
Inter-Client Communication Conventions Manual for complete details.
|
||||
\fIType\fR defaults to STRING.
|
||||
\fIType\fR defaults to \fBSTRING\fR.
|
||||
.PP
|
||||
The \fIformat\fR argument specifies the representation that should be
|
||||
used to transmit the selection to the requester (the second column of
|
||||
Table 2 of the ICCCM), and defaults to STRING. If \fIformat\fR is
|
||||
STRING, the selection is transmitted as 8-bit ASCII characters. If
|
||||
\fIformat\fR is ATOM, then the \fIdata\fR is
|
||||
Table 2 of the ICCCM), and defaults to \fBSTRING\fR. If \fIformat\fR is
|
||||
\fBSTRING\fR, the selection is transmitted as 8-bit ASCII characters. If
|
||||
\fIformat\fR is \fBATOM\fR, then the \fIdata\fR is
|
||||
divided into fields separated by white space; each field is converted
|
||||
to its atom value, and the 32-bit atom value is transmitted instead of
|
||||
the atom name. For any other \fIformat\fR, \fIdata\fR is divided
|
||||
into fields separated by white space and each
|
||||
into fields separated by white space and each
|
||||
field is converted to a 32-bit integer; an array of integers is
|
||||
transmitted to the selection requester. Note that strings passed to
|
||||
\fBclipboard append\fR are concatenated before conversion, so the
|
||||
@@ -69,8 +62,8 @@ boundaries. All items appended to the clipboard with the same
|
||||
.PP
|
||||
The \fIformat\fR argument is needed only for compatibility with
|
||||
clipboard requesters that do not use Tk. If the Tk toolkit is being
|
||||
used to retrieve the CLIPBOARD selection then the value is converted back to
|
||||
a string at the requesting end, so \fIformat\fR is
|
||||
used to retrieve the \fBCLIPBOARD\fR selection then the value is
|
||||
converted back to a string at the requesting end, so \fIformat\fR is
|
||||
irrelevant.
|
||||
.PP
|
||||
A \fB\-\|\-\fR argument may be specified to mark the end of options: the
|
||||
@@ -79,21 +72,30 @@ This feature may be convenient if, for example, \fIdata\fR starts
|
||||
with a \fB\-\fR.
|
||||
.RE
|
||||
.TP
|
||||
\fBclipboard clear\fR ?\fB\-displayof\fR \fIwindow\fR?
|
||||
.
|
||||
Claims ownership of the clipboard on \fIwindow\fR's display and removes
|
||||
any previous contents. \fIWindow\fR defaults to
|
||||
.QW . .
|
||||
Returns an empty string.
|
||||
.TP
|
||||
\fBclipboard get\fR ?\fB\-displayof\fR \fIwindow\fR? ?\fB\-type\fR \fItype\fR?
|
||||
.
|
||||
Retrieve data from the clipboard on \fIwindow\fR's display.
|
||||
\fIWindow\fR defaults to
|
||||
.QW . .
|
||||
\fIType\fR specifies the form in which
|
||||
the data is to be returned and should be an atom name such as STRING
|
||||
or FILE_NAME. \fIType\fR defaults to STRING. This command is
|
||||
the data is to be returned and should be an atom name such as \fBSTRING\fR
|
||||
or \fBFILE_NAME\fR. \fIType\fR defaults to \fBSTRING\fR. This command is
|
||||
equivalent to
|
||||
.QW "\fBselection get \-selection CLIPBOARD\fR" .
|
||||
.QW "\fBselection get\fR \fB\-selection CLIPBOARD\fR" .
|
||||
.RS
|
||||
.PP
|
||||
Note that on modern X11 systems, the most useful type to retrieve for
|
||||
transferred strings is not \fBSTRING\fR, but rather \fBUTF8_STRING\fR.
|
||||
.RE
|
||||
.SH EXAMPLES
|
||||
.PP
|
||||
Get the current contents of the clipboard.
|
||||
.CS
|
||||
if {[catch {\fBclipboard get\fR} contents]} {
|
||||
@@ -146,9 +148,10 @@ bind $c <<Paste>> {
|
||||
}
|
||||
}
|
||||
.CE
|
||||
|
||||
.SH "SEE ALSO"
|
||||
interp(n), selection(n)
|
||||
|
||||
.SH KEYWORDS
|
||||
clear, format, clipboard, append, selection, type
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
10
doc/colors.n
10
doc/colors.n
@@ -205,7 +205,7 @@ goldenrod1 255 193 37
|
||||
goldenrod2 238 180 34
|
||||
goldenrod3 205 155 29
|
||||
goldenrod4 139 105 20
|
||||
gray 190 190 190
|
||||
gray 128 128 128
|
||||
gray0 0 0 0
|
||||
gray1 3 3 3
|
||||
gray2 5 5 5
|
||||
@@ -307,14 +307,14 @@ gray97 247 247 247
|
||||
gray98 250 250 250
|
||||
gray99 252 252 252
|
||||
gray100 255 255 255
|
||||
green 0 255 0
|
||||
green 0 128 0
|
||||
green yellow 173 255 47
|
||||
green1 0 255 0
|
||||
green2 0 238 0
|
||||
green3 0 205 0
|
||||
green4 0 139 0
|
||||
GreenYellow 173 255 47
|
||||
grey 190 190 190
|
||||
grey 128 128 128
|
||||
grey0 0 0 0
|
||||
grey1 3 3 3
|
||||
grey2 5 5 5
|
||||
@@ -534,7 +534,7 @@ magenta1 255 0 255
|
||||
magenta2 238 0 238
|
||||
magenta3 205 0 205
|
||||
magenta4 139 0 139
|
||||
maroon 176 48 96
|
||||
maroon 128 0 0
|
||||
maroon1 255 52 179
|
||||
maroon2 238 48 167
|
||||
maroon3 205 41 144
|
||||
@@ -651,7 +651,7 @@ plum3 205 150 205
|
||||
plum4 139 102 139
|
||||
powder blue 176 224 230
|
||||
PowderBlue 176 224 230
|
||||
purple 160 32 240
|
||||
purple 128 0 128
|
||||
purple1 155 48 255
|
||||
purple2 145 44 238
|
||||
purple3 125 38 205
|
||||
|
||||
@@ -25,7 +25,7 @@ the Tk library. Except for TkAqua, this command is not available when
|
||||
Tk is loaded into a tclsh interpreter with
|
||||
.QW "\fBpackage require Tk\fR" ,
|
||||
as a conventional terminal is expected to be present in that case.
|
||||
In TkAqua, this command is ony available when stdin is \fB/dev/null\fR
|
||||
In TkAqua, this command is only available when stdin is \fB/dev/null\fR
|
||||
(as is the case e.g. when the application embedding Tk is started
|
||||
from the Mac OS X Finder).
|
||||
.PP
|
||||
@@ -129,6 +129,7 @@ Most other behaviour is the same as a conventional text widget except
|
||||
for the way that the \fI<<Cut>>\fR event is handled identically to the
|
||||
\fI<<Copy>>\fR event.
|
||||
.SH EXAMPLE
|
||||
.PP
|
||||
Not all platforms have the \fBconsole\fR command, so debugging code
|
||||
often has the following code fragment in it so output produced by
|
||||
\fBputs\fR can be seen while during development:
|
||||
@@ -139,3 +140,6 @@ catch {\fBconsole show\fR}
|
||||
destroy(n), fconfigure(n), history(n), interp(n), puts(n), text(n), wm(n)
|
||||
.SH KEYWORDS
|
||||
console, interpreter, window, interactive, output channels
|
||||
'\" Local Variables:
|
||||
'\" mode: nroff
|
||||
'\" End:
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user