summaryrefslogtreecommitdiffstats
path: root/generic
Commit message (Collapse)AuthorAgeFilesLines
* * generic/tkGrid.c (GridStructureProc, ConfigureSlaves):mdejong2003-03-123-96/+141
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check for a NULL masterPtr and slavePtr in the GridStructureProc code to ensure that a Gridder created before some error condition is ignored when it comes to geometry calculations. This approach closely matches the pack implementation. Keep track of a -in argument to a grid command in order to detect the case of an already gridded widget that wants to change some options. The previous implementation could make repeated and unnecessary calls to Tk_ManageGeometry. Replace use of "parent" with "master" in comments throughout the file. * generic/tkPack.c (PackStructureProc): Check for a NULL masterPtr before other checks so that a slave created under certain error conditions is cleaned up properly. Replace use of "parent" with "master" in comments throughout the file. * generic/tkPlace.c (CreateSlave, ConfigureSlave, SlaveStructureProc): Don't call Tk_ManageGeometry in CreateSlave since this was causing incorrect results in some error cases. Rework the ConfigureSlave method so that slave setup is done in one place. The call to Tk_ManageGeometry was added to the one place where a slave is setup. When a slave is configured but the master is not changed, simply goto the scheduleLayout label. Check for a NULL master in SlaveStructureProc for the sake of readability. * tests/grid.test: * tests/pack.test: * tests/place.test: Add test to check that a winfo manager call does not return incorrect results after an error condition is hit. [Patch 693063]
* TIP#116 implementation. Docs still to come, tests will never be done becausedkf2003-03-067-76/+277
| | | | | they could never be done portably as they'd inevitably depend on the total amount of memory available to the process... :^(
* * README: Bumped version number ofdgp2003-03-041-8/+8
| | | | | | | | | | | | | | | | | * generic/tk.h: Tk to 8.5a0. * library/tk.tcl: * mac/README: * macosx/Wish.pbproj/project.pbxproj: * unix/README: * unix/configure.in: * unix/tk.spec: * win/README: * win/configure.in: * win/makefile.vc: * win/tcl.m4: * unix/configure: autoconf * win/configure:
* Make all %-expansions generate ?? when their event doesn't have the rightdkf2003-02-281-57/+92
| | | | underlying field to prevent a crash on Windows. [Bug #612110]
* * generic/tkMenu.c (TkMenuCleanup): make sure to reset statichobbs2003-02-261-2/+30
| | | | menusInitialized on finalize. [Bug #548729]
* * generic/tkListbox.c (ListboxSelectionSubCmd):hobbs2003-02-251-11/+15
| | | | | * tests/listbox.test: Allow 'selection includes' to respond when disabled (but only 'includes'). [Bug #632514]
* * generic/tkEntry.c (SpinboxWidgetObjCmd, EntryWidgetObjCmd):hobbs2003-02-251-13/+14
| | | | | | | * tests/entry.test: return 1 if selection is present even if * tests/spinbox.test: entry/spinbox is disabled, as selection get will still return the selection (although selection still ignore modify requests when entry/spinbox is disabled). [Bug #637828]
* Use the panedwindow's depth, not the screen's default depth. [Bug #671122]dkf2003-02-211-5/+3
|
* * tests/panedwindow.test:hobbs2003-02-211-3/+6
| | | | | * generic/tkPanedWindow.c (ValidSashIndex): corrected to note that 2 panes must exist before any one sash does. [tcllib Bug #689258]
* Fixed calculation of the last slave'spspjuth2003-02-201-5/+3
| | | | size when increasing the size of the panedwindow. [Bug #689099]
* Removed pointless static variable ZeroDataBlock from tkImgGIF.c [Bug #664788]dkf2003-02-201-5/+1
| | | | It served no useful purpose whatsoever...
* (EntrySetValue): removed unused code var. [Bug #664781]hobbs2003-02-181-3/+3
|
* (TkPostscriptImage): remove unused depth var. [Bug #664787]hobbs2003-02-181-3/+2
|
* (TextWidgetCmd): remove unused lastEnd var. [Bug #664790]hobbs2003-02-181-4/+3
|
* * generic/tkImgGIF.c (FileReadGIF): Ensure that the trashBuffer isdkf2003-02-181-9/+13
| | | | always deallocated on function exit to stop a potential memory leak.
* * generic/tkEvent.c (Tk_HandleEvent): Fixup buttonmdejong2003-02-182-3/+20
| | | | | | | | | | press state saving code, it was incorrectly converting normal motion events into button press and motion events in some cases. * generic/tkInt.h: Add mouseButtonWindow member to the TkDisplay structure. * tests/event.test: Add test case for faulty button motion logic.
* * README: Bumped to 8.4.2.hobbs2003-02-151-3/+3
| | | | | | | | | | | * generic/tk.h: * macosx/Wish.pbproj/project.pbxproj: * unix/configure: * unix/configure.in: * unix/tcl.m4: * unix/tk.spec: * win/configure: * win/configure.in:
* * generic/tkCanvArc.c (CreateArc): Rework canvas create itemhobbs2003-02-099-366/+355
| | | | | | | | | | | | | | * generic/tkCanvBmap.c (CreateBitmap): type coords handling to be * generic/tkCanvImg.c (CreateImage): consistent across types * generic/tkCanvPoly.c (CreatePolygon): and not pass empty coords * generic/tkCanvLine.c (CreateLine): to item creation procs. * generic/tkCanvText.c (CreateText): * generic/tkCanvWind.c (CreateWinItem): * generic/tkCanvas.c (CanvasWidgetCmd CANV_CREATE): * generic/tkRectOval.c (CreateRectOval): * tests/canvRect.test: * tests/canvText.test: * tests/canvas.test:
* Moved 'deletionEpoch' field from TkDisplay to TkMainInfo.jenglish2003-01-283-57/+61
| | | | | Reworked windowObj type. Fixes Tk Bug #671330 "segfault when e.g. deiconifying destroyed window"
* * generic/tkImage.c (Tk_ImageObjCmd): Added check to make suredkf2003-01-225-5/+76
| | | | | | | | | | | | that you're not creating an image named the same as .'s command, which refixes 220891, even when the name of the command has been changed with 'rename'. The error message is better too. * generic/tkFrame.c (TkToplevelWindowForCommand): Added way of mapping from command names to tkwins-for-toplevels. * tests/image.test (image-1.10,image-1.11): Updated to match new error message and added test for the rename case. * generic/tclInt.decls: Made TkToplevelWindowForCommand exported privately.
* * generic/tkImage.c (DeleteImage): delete the image's entry in thehobbs2003-01-191-4/+2
| | | | | image table correctly when there are no more instances. This reopens bug 220891. [Bug #669759]
* Increase the size of the clipping box for lines in bug #663981 so thatdrh2003-01-171-11/+20
| | | | | Tk extensions that attempt to print a canvas in a windows GDI printer will still work.
* * generic/tkSelect.c (Tk_CreateSelHandler):jenglish2003-01-141-4/+5
| | | | | Fix for #666346 "Selection handling crashes under KDE 3.0" * tests/unixSelect.test (unixSelect-1.20): Added test case.
* Use explicit "static int" type, not implicit "static".dgp2003-01-091-2/+2
|
* Implement Cohen-Sutherland polygon clipping for long lines in the canvas widgetdrh2003-01-083-13/+285
| | | | | so that coordinates do not overflow the 16-bit limit imposed by X11 and Win32. Bug #663981.
* * generic/tkFrame.c (CreateFrame): throw a Tcl error instead of ahobbs2003-01-031-4/+10
| | | | | | panic when we cannot get a main window and appname is NULL. This can indicate that a user tried to create a frame/toplevel while Tk was dying. [Bug #661792]
* ANSI unfriendly typedef for TkTextBTree repaired for C++ compilers.davygrvy2002-12-271-2/+2
|
* * generic/tkMain.c (Tk_Main): Call on Tcl*StartupScript*() routinesdgp2002-12-131-11/+10
| | | | to store the startup script, if any. [Bug 616245].
* * generic/tkEntry.c (ConfigureEntry): keep a flag to indicate whenhobbs2002-12-091-8/+16
| | | | | a var is traced to prevent double-traces caused by configuring the widget in traces with validation on. (dejong)
* * generic/tkInt.decls: add TkWinSetHINSTANCE declhobbs2002-12-083-3/+17
| | | | | | | | | | * generic/tkIntPlatDecls.h: regen * generic/tkStubInit.c: regen * win/tkWinInit.c (TkpInit): While init and cleanup aren't correct * win/tkWinX.c (TkWinXInit): in DllMain, we had to specify the * win/tkWin32Dll.c (DllMain): true HINSTANCE or the resources of a dynamic Tk weren't being loaded correctly. Created a new function TkWinSetHINSTANCE for this purpose.
* * tests/textDisp.test:hobbs2002-11-221-24/+35
| | | | | * generic/tkTextDisp.c (TkTextSeeCmd): handle see for unmapped text displays. [Bug #641778]
* * generic/tkWindow.c (Tk_DestroyWindow,mdejong2002-11-141-28/+122
| | | | | | | | | | | | | | DeleteWindowsExitProc): Add TkHalfdeadWindow type and halfdeadWindowList to keep track of windows that were only partially deallocated before a call to exit. Finnish cleaning up these windows in DeleteWindowsExitProc. Keep track of cleanup status in Tk_DestroyWindow so that a window with a Destroy binding which calls exit will get fully destroyed. * tests/window.test: Add Tk_DestroyWindow tests for an assortment of half dead window cases. [Bug 630533]
* place info did not return all settings,pspjuth2002-11-071-18/+10
| | | | | | and didn't make sure the result was a proper list. Put '-in' first in result to be more consistent with how grid/pack info behaves. [Bug #635025][Bug #532022]
* * tests/imgPhoto.test:hobbs2002-10-181-7/+15
| | | | | * generic/tkImgPhoto.c (ImgPhotoConfigureMaster): fix arg handling for missing -format or -data options. [Bug #624974]
* The grid size was not updated properlypspjuth2002-10-101-8/+3
| | | | when removing a widget from a grid. [Bug #621241] (forssen)
* * generic/tkCanvPs.c (TkImageGetColor): corrected bogus use ofhobbs2002-10-101-12/+28
| | | | | | | | TkColormapData on Windows (Windows now requires RGB pixel data from image). * win/tkWinImage.c (XGetImage, XGetImageZPixmap): added support for generating ps for embedded widgets on canvases on Windows, tested for 8, 16, 24 and 32-bit depths (XGetImageZPixmap not used).
* * tests/canvPs.test: tests for canvas embedded window ps generationhobbs2002-10-103-37/+38
| | | | | | | | | | * generic/tkCanvWind.c (CanvasPsWindow): removed dead code loop. * generic/tkCanvas.h: moved TkColormapData struct to tkCanvPs.c * generic/tkCanvPs.c (TkImageGetColor): corrected bogus use of TkColormapData on Windows. Non-separated data may need correction as well. * win/tkWinImage.c (XGetImage, XGetImageZPixmap): added support for generating ps for embedded windows on canvases.
* * generic/tk.h: Added reminder comment to editdgp2002-10-091-1/+3
| | | | macosx/Wish.pbproj/project.pbxproj when version number changes.
* * generic/tkInt.decls(tkIntXlib): added XQueryTree declaration fordas2002-10-093-3/+28
| | | | | | | | | | | | | | | | | | | mac & aqua, since it's now called from ParentXId via Tk_HandleEvent. * generic/tkIntXlibDecls.h: * generic/tkStubInit.c: regen. * mac/tkMacXStubs.c: added XQueryTree stub * mac/tkMacEmbed.c (TkpUseWindow): check that container window has -container option set (sync with other platforms). * mac/tkMacBitmap.c: * mac/tkMacFont.c: * mac/tkMacSend.c: * mac/tkMacTest.c: * mac/tkMacWm.c: CONSTification. * mac/tkMacProjects.sea.hqx: added tkStyle.c and tkUndo.c to tk library projects.
* * generic/tkImgPhoto.c (ImgPhotoSetSize): Only error-out if wedkf2002-10-091-40/+48
| | | | | | | | | fail to allocate a non-empty buffer; getting a NULL when we allocate an empty buffer is no problem since nothing will look at the value anyway. [Bug 619544] Also tidied up file to take into account the fact that we're using 32 bits per pixel in the master to accommodate the alpha channel as well as RGB.
* * generic/tkFocus.c (TkFocusFilterEvent): Ignore event if we arehobbs2002-10-081-3/+10
| | | | focusing into a dead window. [Bug #588831] (griffin)
* * generic/tkPanedWindow.c (Tk_PanedWindowObjCmd): leave thehobbs2002-10-081-7/+13
| | | | | | DestroyPanedWindow proc to free the pwPtr, add a Preserve reference to the pwPtr->tkwin. (DestroyPanedWindow): Release the pwPtr->tkwin.
* * generic/tkText.c (TextBlinkProc): don't blink the cursor unlesshobbs2002-10-021-4/+5
| | | | it is visible. [Bug #616791] [Patch #614474] (bonfield)
* * tests/entry.test: added entry-20.7hobbs2002-10-021-1/+8
| | | | | | * generic/tkEntry.c (EntryTextVarProc): check if the entry if being deleted before handling an associated textvariable. [Bug #607390 #617446]
* * tests/panedwindow.test: added panedwindow-28.[12]hobbs2002-09-301-3/+3
| | | | | | | * generic/tkPanedWindow.c (PanedWindowCmdDeletedProc): (Tk_PanedWindowObjCmd): when destroying the panedwindow, destroy the proxy before the parent to avoid dependency conflicts. [Bug #616589]
* * README: Bumped to version 8.4.1 to avoid confusiondgp2002-09-271-3/+3
| | | | | | | | | | | * generic/tk.h: of CVS snapshots with release 8.4.0. * unix/README: * unix/configure.in: * unix/tk.spec * win/configure.in: * unix/configure: autoconf * win/configure:
* * generic/tk.h: Moved RC_INVOKED down so that tcl.h is stillandreas_kupries2002-09-141-13/+13
| | | | | | | | included when running the resource compiler. <tcl.h> excludes the unnecessary parts on its own. This reenables the Windows build. It failed because the non-inclusion of tcl.h caused the resource compiler to miss some vital macro definitions (TCL_FINAL_RELEASE, STRINGIFY, ...).
* * generic/tk.h:das2002-09-121-16/+11
| | | | | | | | | | | | | | | | | | * mac/tkMacApplication.r: * mac/tkMacLibrary.r: * mac/tkMacResource.r: * macosx/tkAboutDlg.r: * macosx/tkMacOSXApplication.r: * macosx/tkMacOSXLibrary.r: * macosx/tkMacOSXResource.r: unified use of the two equivalent resource compiler header inclusion defines RC_INVOKED and RESOURCE_INCLUDED, now use RC_INVOKED throughout. * macosx/tkMacOSXAppInit.c: improved detection of Wish startup by the finder (by checking if stdin is /dev/null), in which case we want to bring up the Tk console window. * macosx/tkMacOSXHLEvents.c: added 'rapp' apple event handler.
* Bumped version number to 8.4.0hobbs2002-09-021-4/+4
|
* * generic/tkCmds.c:hobbs2002-09-022-9/+30
| | | | | | | * generic/tkWindow.c: made 'tk' available in safe interpreters, but only the caret and windowingsystem subcommands may be called. * tests/safe.test (safe-1.2): noted that tk is now available in safe interps, but not the appname/scaling subcommands.