summaryrefslogtreecommitdiffstats
path: root/generic/tkTreeStyle.c
Commit message (Collapse)AuthorAgeFilesLines
* Fixed partially-exposed transparent photo images not being redrawn when ↵treectrl2007-04-211-3/+5
| | | | scrolling under X11. This involved creating a wrapper around Tk_RedrawImage to ensure proper clipping of the source image to the bounds of the destination drawable. A new data type TreeDrawable remembers the height and width of a drawable.
* Make TreeElemTypeXXX variables start with lowercase letter.treectrl2007-01-311-15/+15
|
* Renamed many symbols to avoid collisions under ELF.treectrl2007-01-231-133/+139
| | | | Renamed Element to TreeElement_.
* Formatting of braces (again).treectrl2006-12-231-63/+26
|
* Formatting of braces.treectrl2006-12-221-731/+377
|
* New style layout option -draw deprecates the -draw option of every element.treectrl2006-12-071-28/+83
|
* Hide window elements if changing the -visible layout option causes the ↵treectrl2006-12-071-4/+15
| | | | window element to become hidden.
* Revert the change involving hiding elements that had non-zero size. Just ↵treectrl2006-12-061-36/+11
| | | | rely on the style layout option -visible.
* New style layout option -visible.treectrl2006-12-041-25/+165
| | | | | Elements with zero requested size are not included in the layout, including any padding. Union elements are not included in the layout if all the elements they surround are hidden or have zero size.
* Don't layout elements whose requested size is zero.treectrl2006-12-021-62/+207
|
* Fix potential segfaults when a display update is requested in the middle of ↵treectrl2006-11-251-6/+28
| | | | drawing items.
* Fixed crash with [style elements] when items were using the style.treectrl2006-11-231-11/+12
|
* Changed Style_NeededSize to calculate the needed and minimum sizes in one ↵treectrl2006-11-231-46/+36
| | | | call, rather than calling it twice.
* Added some conditional compilation around the size cache of elements and ↵treectrl2006-11-221-90/+297
| | | | styles to test performance without it.
* Removed a useless #args check from [element delete] and added one to ↵treectrl2006-11-121-6/+6
| | | | [element names].
* Fixed crash with incorrect number of args in [element perstate].treectrl2006-11-101-2/+2
|
* TreeStyle_ValidateElements no longer used.treectrl2006-11-071-7/+12
|
* Deprecated the treectrl option -defaultstyle.treectrl2006-11-031-1/+10
| | | | Added column option -itemstyle (replaces -defaultstyle).
* Fix compilation when ALLOC_HAX is undefined.treectrl2006-11-031-3/+3
|
* Fixed a crash when a master element calls Tree_ElementChangedItself.treectrl2006-10-301-22/+25
| | | | Pass element index to Style_ElementChanged so instance styles don't need to be searched for every item-column.
* Changed dynamic-option code to use AllocHax_xxx.treectrl2006-10-261-4/+4
|
* Merged with BRANCH_dynamic_options.treectrl2006-10-181-1/+11
|
* AllocHax_xxx takes a Tk_Uid arg for gathering stats on memory allocations.treectrl2006-10-161-28/+43
| | | | Lowered memory usage by lowering the "round up" argument to AllocHax_CAlloc.
* Remove rowlabels.treectrl2006-10-141-239/+2
|
* Added StyleDrawArgs.bounds for clipping window elements.treectrl2006-10-111-43/+56
| | | | Tree_InvalidateItemDInfo and Tree_InvalidateColumnWidth now take a TreeColumn arg.
* Separated Style into MStyle and IStyle to save some memory.treectrl2006-10-041-356/+827
| | | | | ElementLink -> MElementLink and IElementLink. Rowlabels use styles too, so they get updated when styles/elements change.
* Set ElementArgs.display.bounds in two places to support clipping of window ↵treectrl2006-09-271-3/+27
| | | | elements.
* Use new Tree_StateFromListObj for getting state flags from a list object.treectrl2006-09-221-11/+2
|
* Bumped copyright to 2006.treectrl2006-09-051-2/+2
|
* Fix cut-and-paste error in comment.treectrl2006-07-111-2/+2
|
* Converted to tab+space indentation.treectrl2005-09-161-4131/+4137
|
* Add Tcl block comments above each function. Comment function arguments.treectrl2005-09-151-102/+1705
|
* Style_DoLayoutH/V: Removed unused return values.treectrl2005-09-071-21/+12
| | | | Replaced wipefree() with WCFREE().
* * generic/tkTreeStyle.c (Style_DoLayout): use if instead ofhobbs22005-08-101-4/+6
| | | | tertiary ?: operator for funcs with different return types.
* Eliminate "type-punned pointer" warnings from GCC.treectrl2005-07-231-16/+17
|
* Added [element perstate] command.treectrl2005-07-151-3/+39
|
* Add TreeStyle_GetImage and TreeStyle_SetImage.treectrl2005-07-121-27/+56
|
* TreeStyle_Draw: added call to Style_CheckNeededSize.treectrl2005-07-051-6/+7
| | | | Renamed TreeStyle_HideWindows to TreeStyle_OnScreen, and use the new ElementType.onScreen callback.
* Style_DoLayoutH: Allow column justification to occur when a -detach element ↵treectrl2005-06-201-86/+77
| | | | | | | | is larger than the non-union, non-detach elements. Previously justification would only occur if the available space was greater than that needed by the style. Style_DoLayoutH: Allow column justification to occur when elements expand horizontally. This applies when -expand and -iexpand do not specify w or e, but -iexpand does specify x, and the -maxwidth is not {}. Basically, if there is some space left over after expansion then justification will occur. Style_DoLayoutH/V: The internal padding is added to the display area of -union elements, and the internal padding is set to zero. This works in conjunction with the changes in TreeStyle_Draw and TreeStyle_UpdateWindowPositions. TreeStyle_Draw/TreeStyle_UpdateWindowPositions: Fixed bug where -union elements were not displayed if the elements they surrounded had zero height or width. Also removed ElementArgs.display.pad and ElementArgs.display.squeeze which were unused.
* Allow expansion of non-detach non-union elements if a -detach element is ↵treectrl2005-06-151-254/+200
| | | | | | larger than them all. Previously expansion would only occur if the available space was greater than the needed space of the style. Alphabetized style layout options, and moved option-to-Tcl_Obj code to a new function.
* Removed gobs of conditional compilation code.treectrl2005-06-141-362/+7
|
* Style_DoExpandH rearranged to allocate space to the right padding before the ↵treectrl2005-06-131-206/+405
| | | | | | | | | | | | | left. Style_DoExpandV rewritten to use the same algorithm as Style_DoExpandH. Style_DoLayoutH: properly calculate Layout.useWidth for -union layout. Style_DoLayoutV: expand elements vertically using same algorithm as Style_DoLayoutH. Changed Style_DoLayout to use the new ElementType.heightProc. Also consider the -minheight, -height, and -maxheight style layout options. Style_NeededSize: consider min/max width/height style layout options. ElementType.layoutProc renamed to ElementType.neededProc. TreeStyle_NeededHeight: basically the same, but doesn't return Style.minHeight since that didn't take into account text wrapping. TreeStyle_Draw/TreeStyle_UpdateWindowPositions/TreeStyle_GetElemRects: the -ipadx and -ipady padding is no longer added to the display area of an element (although there is no change wrt -union layout). StyleLayoutCmd: fixed bug where -iexpand xy were not cleared.
* New style layout option "-sticky" controls how an element is ↵treectrl2005-06-101-281/+384
| | | | | | | stretched/positioned within its parcel of space. Extended -iexpand option to accept x and y chars, to allow the parcel of space to be expanded. Previously only the -ipad values were stretched by -iexpand. New style layout options -maxwidth and -maxheight.
* Rewrote Style_DoExpandH and Style_DoExpandV to handle -expand and -iexpand ↵treectrl2005-06-081-6/+237
| | | | | | at the same time. Previously -expand was ignored if -iexpand was specified. "style layout $S $E -detach" and "style layout $S $E -indent" return "yes" or "no" instead of "1" or "0" to agree with "style layout $S $E".
* Fixed panic attacks in Style_DoLayout caused by LAYOUTHAX changes (caller ↵treectrl2005-06-061-84/+54
| | | | | | was not setting drawArgs->width properly). Properly save/restore config options in "style layout" command upon error.
* LAYOUTHAX code accepted, removed conditional compilation.treectrl2005-06-061-164/+32
|
* Added -minwidth, -minheight, -width, -height style layout options.treectrl2005-06-061-33/+291
|
* Fixed y-position bug in Style_DoLayoutV.treectrl2005-06-041-135/+107
| | | | | | | | | Fixed bug calculating needed height of style with -union elements. Not sure how Style_DoLayoutNeededV ever worked correctly. Combined Style_DoLayout and Style_DoLayout2 since they were 99% the same. Changed Style_NeededSize to return whether the style has any -squeeze elements. This is used to avoid an unnecessary call when determining the minimum style size. Optimize TreeStyle_NeededWidth/Height by using cached values. NEEDED_HAX code present simply to test that I am allowed to use those cached values. Optimize TreeStyle_UseHeight by using cached values. Style.layoutWidth already existed for this purpose but wasn't set properly. Changed TreeStyle_UndefineState to always invalidate the layout of every element/column/item.
* Fixed bug with calculation of needed size of a style.treectrl2005-06-021-7/+41
| | | | | | Fixed drawing bug caused by LAYOUT_HAX changes. Add some calls to Tree_FreeItemDInfo. Replace some calls to Tree_InvalidateItemDInfo with Tree_FreeItemDInfo.
* Fix layout bug with new LAYOUT_HAX code.treectrl2005-05-281-1/+11
|