Lines Matching full:item

100 an item will jump to it. Item values can be toggled directly within the dialog.\
124 # The Label that shows the menu path of the selected item
134 # We can't use Node objects directly as Treeview item IDs, so we use their
215 # Select the first item and focus the Treeview, so that keyboard controls
581 item = node.item
583 values=item.name if item.__class__ is Symbol_ else "")
659 # If a selected/focused item is detached and later reattached, it stays
690 if node.list and not isinstance(node.item, Symbol):
691 if _tree.item(id(node), "open"):
713 if node.list and isinstance(node.item, Symbol):
717 elif node.list and isinstance(node.item, Symbol):
754 elif node.list and isinstance(node.item, Symbol):
757 # Invisible item with visible children
774 (node.item == MENU and not expr_value(node.visibility))
784 _tree.item(
799 if node.item == COMMENT:
804 if isinstance(node.item, Symbol):
805 sym = node.item
815 elif isinstance(node.item, Symbol):
817 s = "<{}>".format(node.item.name)
822 s = standard_sc_expr_str(node.item)
825 if isinstance(node.item, Symbol):
826 sym = node.item
832 elif isinstance(node.item, Choice) and node.item.tri_value == 2:
835 sym = node.item.selection
864 item = node.item
866 if item in (MENU, COMMENT) or not item.orig_type:
869 if item.orig_type in (STRING, INT, HEX):
874 if _is_y_mode_choice_sym(item):
876 return "selected" if item.choice.selection is item else "not-selected"
878 if len(item.assignable) <= 1:
880 return "" if isinstance(item, Choice) else item.str_value + "-locked"
882 if item.type == BOOL:
883 return item.str_value + "-bool"
885 # item.type == TRISTATE
886 if item.assignable == (1, 2):
887 return item.str_value + "-my"
888 return item.str_value + "-tri"
891 def _is_y_mode_choice_sym(item): argument
895 return isinstance(item, Symbol) and item.choice and item.visibility == 2
903 item = tree.identify_row(event.y)
904 # Select the item before possibly popping up a dialog for
906 _select(tree, item)
907 _change_node(_id_to_node[item], tree.winfo_toplevel())
1002 sc = node.item
1017 def _tree_toggle_open(item): argument
1018 # Opens/closes the Treeview item 'item'
1020 if _tree.item(item, "open"):
1021 _tree.item(item, open=False)
1023 node = _id_to_node[item]
1024 if not isinstance(node.item, Symbol):
1027 _tree.item(item, open=True)
1034 # Sets the value of the currently selected item to 'tri_val', if that
1039 sc = _id_to_node[sel].item
1059 if not isinstance(node.item, Symbol):
1071 def _item_row(item): argument
1072 # Returns the row number 'item' appears on within the Kconfig treeview,
1081 prev = _tree.prev(item)
1083 item = prev
1084 row += _n_rows(item)
1086 item = _tree.parent(item)
1087 if not item:
1092 def _n_rows(item): argument
1093 # _item_row() helper. Returns the number of rows occupied by 'item' and #
1098 if _tree.item(item, "open"):
1099 for child in _tree.get_children(item):
1105 def _attached(item): argument
1106 # Heuristic for checking if a Treeview item is attached. Doesn't seem to be
1110 return bool(_tree.next(item) or _tree.prev(item) or _tree.parent(item))
1122 sc = node.item
1164 stayput = _loc_ref_item() # Item to preserve scroll for
1169 # If the reference item disappeared (can happen if the change was done
1200 sym = node.item
1491 # reference item isn't shown (only invisible items on the screen, and
1555 # Enters the menu 'menu' and selects the first item. Used in single-menu
1592 def _select(tree, item): argument
1593 # Selects, focuses, and see()s 'item' in 'tree'
1595 tree.selection_set(item)
1596 tree.focus(item)
1597 tree.see(item)
1601 # Returns a Treeview item that can serve as a reference for the current
1602 # scroll location. We try to make this item stay on the same row on the
1605 # If the selected item is visible, use that
1610 # Otherwise, use the middle item on the screen. If it doesn't exist, the
1611 # tree is probably really small, so use the first item in the entire tree.
1617 # Like _loc_ref_item(), but finds a visible item around the reference item.
1621 item = _loc_ref_item()
1623 vis_before = _vis_before(item)
1627 vis_after = _vis_after(item)
1634 def _vis_before(item): argument
1635 # _vis_loc_ref_item() helper. Returns the first visible (not red) item,
1636 # searching backwards from 'item'.
1638 while item:
1639 if not _tree.tag_has("invisible", item):
1640 return item
1642 prev = _tree.prev(item)
1643 item = prev if prev else _tree.parent(item)
1648 def _vis_after(item): argument
1649 # _vis_loc_ref_item() helper. Returns the first visible (not red) item,
1650 # searching forwards from 'item'.
1652 while item:
1653 if not _tree.tag_has("invisible", item):
1654 return item
1656 next = _tree.next(item)
1658 item = next
1660 item = _tree.parent(item)
1661 if not item:
1663 item = _tree.next(item)
1820 jumpto_button = ttk.Button(dialog, text="Jump to selected item",
1883 sc = node.item
1916 item = id(_jump_to_matches[0])
1917 _jump_to_tree.selection_set(item)
1918 _jump_to_tree.focus(item)
1926 item = _jump_to_tree.item
1932 item(id_(node),
1993 # jumping to an item needs its parent menus to be populated. This function
2005 if not _tree.item(id(parent), "open"):
2011 if not isinstance(parent.item, Symbol):
2044 if isinstance(node.item, Symbol):
2045 sym = node.item
2056 if isinstance(node.item, Choice):
2057 choice = node.item
2069 # node.item in (MENU, COMMENT)
2237 def _kconfig_def_info(item): argument
2238 # Returns a string with the definition of 'item' in Kconfig syntax,
2241 nodes = [item] if isinstance(item, MenuNode) else item.nodes
2283 standard_sc_expr_str(node.item)) + path