Class: Fox::FXFoldingItem

Inherits:
FXObject show all
Includes:
Enumerable
Defined in:
rdoc-sources/FXFoldingList.rb,
lib/fox16/iterators.rb

Overview

An FXFoldingItem is an item in an FXFoldingList widget.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from FXObject

#bind, #handle, #load, #save, subclasses

Constructor Details

#initialize(text, openIcon = nil, closedIcon = nil, data = nil) ⇒ FXFoldingItem

Construct a new folding item


59
60
# File 'rdoc-sources/FXFoldingList.rb', line 59

def initialize(text, openIcon=nil, closedIcon=nil, data=nil) # :yields: theItem
end

Instance Attribute Details

#aboveObject (readonly)

Item logically above this item Fox::FXFoldingItem


26
27
28
# File 'rdoc-sources/FXFoldingList.rb', line 26

def above
  @above
end

#belowObject (readonly)

Item logically below this item Fox::FXFoldingItem


23
24
25
# File 'rdoc-sources/FXFoldingList.rb', line 23

def below
  @below
end

#closedIconObject

Closed icon Fox::FXIcon


38
39
40
# File 'rdoc-sources/FXFoldingList.rb', line 38

def closedIcon
  @closedIcon
end

#dataObject

User data [Object]


41
42
43
# File 'rdoc-sources/FXFoldingList.rb', line 41

def data
  @data
end

#draggable=(value) ⇒ Object (writeonly)

Indicates whether the item is draggable [Boolean]


56
57
58
# File 'rdoc-sources/FXFoldingList.rb', line 56

def draggable=(value)
  @draggable = value
end

#enabled=(value) ⇒ Object (writeonly)

Indicates whether the item is enabled [Boolean]


53
54
55
# File 'rdoc-sources/FXFoldingList.rb', line 53

def enabled=(value)
  @enabled = value
end

#expanded=(value) ⇒ Object (writeonly)

Indicates whether the item is expanded [Boolean]


50
51
52
# File 'rdoc-sources/FXFoldingList.rb', line 50

def expanded=(value)
  @expanded = value
end

#firstObject (readonly)

First child item Fox::FXFoldingItem


17
18
19
# File 'rdoc-sources/FXFoldingList.rb', line 17

def first
  @first
end

#lastObject (readonly)

Last child item Fox::FXFoldingItem


20
21
22
# File 'rdoc-sources/FXFoldingList.rb', line 20

def last
  @last
end

#nextObject (readonly)

Next sibling item Fox::FXFoldingItem


11
12
13
# File 'rdoc-sources/FXFoldingList.rb', line 11

def next
  @next
end

#numChildrenObject (readonly)

Number of child items [Integer]


29
30
31
# File 'rdoc-sources/FXFoldingList.rb', line 29

def numChildren
  @numChildren
end

#opened=(value) ⇒ Object (writeonly)

Indicates whether the item is opened [Boolean]


47
48
49
# File 'rdoc-sources/FXFoldingList.rb', line 47

def opened=(value)
  @opened = value
end

#openIconObject

Open icon Fox::FXIcon


35
36
37
# File 'rdoc-sources/FXFoldingList.rb', line 35

def openIcon
  @openIcon
end

#parentObject (readonly)

Parent item Fox::FXFoldingItem


8
9
10
# File 'rdoc-sources/FXFoldingList.rb', line 8

def parent
  @parent
end

#prevObject (readonly)

Previous sibling item Fox::FXFoldingItem


14
15
16
# File 'rdoc-sources/FXFoldingList.rb', line 14

def prev
  @prev
end

#selected=(value) ⇒ Object (writeonly)

Indicates whether the item is selected [Boolean]


44
45
46
# File 'rdoc-sources/FXFoldingList.rb', line 44

def selected=(value)
  @selected = value
end

#textObject

Item text [String]


32
33
34
# File 'rdoc-sources/FXFoldingList.rb', line 32

def text
  @text
end

Instance Method Details

#childOf?(item) ⇒ Boolean

Return true if this item is a descendant of item.

Returns:

  • (Boolean)

92
# File 'rdoc-sources/FXFoldingList.rb', line 92

def childOf?(item); end

#createObject

Create this folding item


111
# File 'rdoc-sources/FXFoldingList.rb', line 111

def create; end

#destroyObject

Destroy this folding item


117
# File 'rdoc-sources/FXFoldingList.rb', line 117

def destroy; end

#detachObject

Detach this folding item


114
# File 'rdoc-sources/FXFoldingList.rb', line 114

def detach; end

#draggable?Boolean

Returns true if this item is draggable

Returns:

  • (Boolean)

81
# File 'rdoc-sources/FXFoldingList.rb', line 81

def draggable? ; end

#eachObject

Calls block once for each child of this folding list item, passing a reference to that child item as a parameter.


53
54
55
56
57
58
59
60
61
# File 'lib/fox16/iterators.rb', line 53

def each # :yields: aFoldingItem
  current = first
  while current != nil
    next_current = current.next
    yield current
    current = next_current
  end
  self
end

#enabled?Boolean

Returns true if this item is enabled

Returns:

  • (Boolean)

78
# File 'rdoc-sources/FXFoldingList.rb', line 78

def enabled? ; end

#expanded?Boolean

Returns true if this item is expanded

Returns:

  • (Boolean)

75
# File 'rdoc-sources/FXFoldingList.rb', line 75

def expanded? ; end

#getHeight(foldingList) ⇒ Object

Get the height of this item


108
# File 'rdoc-sources/FXFoldingList.rb', line 108

def getHeight(foldingList) ; end

#getWidth(foldingList) ⇒ Object

Get the width of this item


105
# File 'rdoc-sources/FXFoldingList.rb', line 105

def getWidth(foldingList) ; end

#hasFocus?Boolean

Returns true if this item has the focus

Returns:

  • (Boolean)

66
# File 'rdoc-sources/FXFoldingList.rb', line 66

def hasFocus? ; end

#hasItems=(flag) ⇒ Object

Change has items flag to true or false.


87
# File 'rdoc-sources/FXFoldingList.rb', line 87

def hasItems=(flag); end

#hasItems?Boolean

Return true if subitems, real or imagined

Returns:

  • (Boolean)

84
# File 'rdoc-sources/FXFoldingList.rb', line 84

def hasItems?; end

#opened?Boolean

Returns true if this item is opened

Returns:

  • (Boolean)

72
# File 'rdoc-sources/FXFoldingList.rb', line 72

def opened? ; end

#parentOf?(item) ⇒ Boolean

Return true if this item is an ancestor of item.

Returns:

  • (Boolean)

97
# File 'rdoc-sources/FXFoldingList.rb', line 97

def parentOf?(item); end

#selected?Boolean

Returns true if this item is selected

Returns:

  • (Boolean)

69
# File 'rdoc-sources/FXFoldingList.rb', line 69

def selected? ; end

#setClosedIcon(icn, owned = false) ⇒ Object

Change closed icon to icn, deleting old icon if it was owned. If owned is true, mark icn as owned by this folding item.


129
# File 'rdoc-sources/FXFoldingList.rb', line 129

def setClosedIcon(icn, owned=false); end

#setFocus(focus) ⇒ Object

Set the focus on this folding item (focus is either true or false)


63
# File 'rdoc-sources/FXFoldingList.rb', line 63

def setFocus(focus) ; end

#setOpenIcon(icn, owned = false) ⇒ Object

Change open icon to icn, deleting old icon if it was owned. If owned is true, mark icn as owned by this folding item.


123
# File 'rdoc-sources/FXFoldingList.rb', line 123

def setOpenIcon(icn, owned=false); end

#to_sObject

Returns the item's text


100
101
102
# File 'rdoc-sources/FXFoldingList.rb', line 100

def to_s
  text
end