Unnamed Fossil Project

Check-in [6d5e4aeec4]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:initial version
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:6d5e4aeec4c1f522c455e577cfc981bc289f6442
User & Date: arnulf 2013-09-14 20:38:53
Context
2013-09-14
20:49
initial version check-in: 933694c7ea user: arnulf tags: trunk
20:38
initial version check-in: 6d5e4aeec4 user: arnulf tags: trunk
20:15
a lot of new code for panedwindow and fixes check-in: 5ad022d324 user: arnulf tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Added library/ntkTreeview.tcl.



















































































































































































>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
#---------------------------------------------------------------------------
# ntkWidget ntkTreeview.tcl --
#
# This file contains a ntkWidget treeview commands implementation
#
# this code is derived from the tile/ttk implementation written by
# Joe English
#
# Copyright (c) 2013 by Arnulf P. Wiedemann
#
# See the file "license.terms" for information on usage and redistribution of
# this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
# RCS: @(#) $Id: ntkTreeview.tcl
#--------------------------------------------------------------------------

namespace eval ::ntk::classes {

::itcl::extendedclass treeview {
    constructor {args} {}

    public proc Treeview_Init {}
}

#================================ Treeview_Init ============================
#     
#=========================================================================

::itcl::body treeview::Treeview_Init {} {
#puts stderr "==== treeview::Treeview_Init"
    set theme [::ntk::classes::theme::GetDefaultTheme]
 
    # treeview
set spec \
  [list Treeview.field [list -sticky nswe -border 1 -pack "" -child \
    [list Treeview.padding [list -sticky nswe -pack "" -child \
      [list Treeview.treearea [list -sticky nswe -pack "" \
      ]] \
    ]] \
  ]]
    ::ntk::classes::theme::RegisterLayout $theme "Treeview" $spec

    # Item
set spec \
  [list Treeitem.padding [list -sticky nswe -pack "" -child \
    [list Treeitem.indicator [list -sticky "" -pack "pack_left" -next \
    [list Treeitem.image [list -sticky "" -pack "pack_left" -next \
    [list Treeitem.focus [list -sticky "" -pack "pack_left" -child \
      [list Treeitem.text [list -sticky "" -pack "pack_left" \
      ]] \
    ]] \
    ]] \
    ]] \
  ]]
    ::ntk::classes::theme::RegisterLayout $theme "Item" $spec

    # Cell
set spec \
  [list Treedata.padding [list -sticky nswe -pack "" -child \
    [list Treeitem.text [list -sticky nswe -pack "" \
    ]] \
  ]]
    ::ntk::classes::theme::RegisterLayout $theme "Cell" $spec

    # Heading
set spec \
  [list Treeheading.cell [list -sticky nswe -pack "" -next \
  [list Treeheading.border [list -sticky nswe -pack "" -child \
    [list Treeheading.padding [list -sticky nswe -pack "" -child \
      [list Treeheading.image [list -sticky nswe -pack "pack_right" -next \
      [list Treeheading.text [list -sticky we -pack "" \
      ]] \
      ]] \
    ]] \
  ]] \
  ]]
    ::ntk::classes::theme::RegisterLayout $theme "Heading" $spec

 
    # Row
set spec \
  [list Treeitem.row [list -sticky nswe -pack "" \
  ]]
    ::ntk::classes::theme::RegisterLayout $theme "Row" $spec

#puts stderr "---- treeview::Treeview_Init"
}

} ; # end namespace ::ntk::classes