Livecode Wiki
 
(Adding categories)
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
Specifies whether an [[object(glossary)]] can be seen or is hidden.Syntax:
+
Specifies whether an object can be seen or is hidden.Syntax:
 
set the [effective] visible of <nowiki><object></nowiki> to {true | false}
 
set the [effective] visible of <nowiki><object></nowiki> to {true | false}
   
Line 9: Line 9:
 
put the effective visible of button "save"
 
put the effective visible of button "save"
   
Use the [[visible]] [[property]] to determine whether an [[object(glossary)]]
+
Use the [[visible]] property to determine whether an object
is hidden or not, or to hide or show an [[object(glossary)]].
+
is hidden or not, or to hide or show an object.
   
 
A hidden object is still present and still takes up memory, and a
 
A hidden object is still present and still takes up memory, and a
Line 17: Line 17:
   
 
An object that cannot be seen only because it's behind another object is
 
An object that cannot be seen only because it's behind another object is
still visible, in the sense that its [[visible]] [[property]] is still true.
+
still visible, in the sense that its [[visible]] property is still true.
   
The [[visible]] [[property]] of [[grouped control|grouped controls]] is
+
The [[visible]] property of grouped controls is
independent of the [[visible]] [[property]] of the [[group(command)]]. Setting
+
independent of the [[visible]] property of the group. Setting
a [[group(glossary)|group's]] [[visible]] [[property]] to false doesn't change
+
a group's [[visible]] property to false doesn't change
the [[visible]] [[property]] of its [[control|controls]]; their [[visible]]
+
the [[visible]] property of its controls; their [[visible]]
[[property]] is still true, even though the [[control|controls]] cannot be
+
[[property]] is still true, even though the controls cannot be
seen because the [[group(command)]] is invisible.
+
seen because the group is invisible.
   
 
If you specify the effective keyword the visible property of a control
 
If you specify the effective keyword the visible property of a control
Line 30: Line 30:
 
visible.
 
visible.
   
You can set the [[visible]] [[property]] of a [[card(keyword)]], but doing so
+
You can set the [[visible]] property of a card, but doing so
has no effect. [[card(object)|Cards]] cannot be made invisible.
+
has no effect. Cards cannot be made invisible.
   
The [[visible]] [[property]] is the logical inverse of the [[invisible]]
+
The [[visible]] property is the logical inverse of the [[invisible]]
[[property]]. When an [[object|object's]] [[visible]] is true, its [[invisible]]
+
property. When an object's [[visible]] is true, its [[invisible]]
 
is false, and vice versa.
 
is false, and vice versa.
   
See also: [[card]] (object),[[control]] (object),[[showInvisibles]] (property),[[invisible]] (property),
+
See also: [[card]] (object), [[control]] (object), [[showInvisibles]] (property), [[invisible]] (property),
 
[[Category: ui]]
 
[[Category: ui]]
  +
[[Category:GUI]]

Latest revision as of 23:46, 1 March 2018

Specifies whether an object can be seen or is hidden.Syntax:

set the [effective] visible of <object> to {true | false}

Examples:

set the visible of stack "Palette" to false
set the visible of me to (not the visible of me)
put the effective visible of button "save"

Use the visible property to determine whether an object is hidden or not, or to hide or show an object.

A hidden object is still present and still takes up memory, and a handler can access its properties and contents, but the user cannot see or or interact with it.

An object that cannot be seen only because it's behind another object is still visible, in the sense that its visible property is still true.

The visible property of grouped controls is independent of the visible property of the group. Setting a group's visible property to false doesn't change the visible property of its controls; their visible property is still true, even though the controls cannot be seen because the group is invisible.

If you specify the effective keyword the visible property of a control returns true if, and only if, the control and all it's parent groups are visible.

You can set the visible property of a card, but doing so has no effect. Cards cannot be made invisible.

The visible property is the logical inverse of the invisible property. When an object's visible is true, its invisible is false, and vice versa.

See also: card (object), control (object), showInvisibles (property), invisible (property),