Difference between revisions of "Text Command"

From GeoGebra Manual
Jump to: navigation, search
m (Text replace - "<div class="box info"> 48px|left This page is part of the official manual for print and pdf. For structural reasons normal users can't edit this page. If you found any errors on this page please contact )
Line 1: Line 1:
 
<noinclude>{{Manual Page|version=4.2}}</noinclude>
 
<noinclude>{{Manual Page|version=4.2}}</noinclude>
 
{{command|text}}
 
{{command|text}}
; Text[Object]: Returns the formula for the object as a [[texts|text object]].
+
; Text[ <Object> ]
 +
: Returns the formula for the object as a [[texts|text object]].
 
: {{Note| By default, values are substituted for variables.}}
 
: {{Note| By default, values are substituted for variables.}}
: {{Example|1=If ''a = 2'' and ''c = a<sup>2</sup>'', then <code>Text[c]</code> returns the text "4".}}
+
: {{Example|1=If ''a = 2'' and ''c = a<sup>2</sup>'', then <code>Text[c]</code> returns the text ''"4"''.}}
; Text[Object, Boolean]: Returns the formula for the object as a text object. The Boolean variable determines if values are substituted for variables (''true'') or if variable names are shown in the text (''false'').
+
; Text[ <Object>, <Boolean for Substitution of Variables> ]
 +
: Returns the formula for the object as a text object. The Boolean variable determines if values are substituted for variables (''true'') or if variable names are shown in the text (''false'').
 
:{{Example|1=<div>If ''a = 2'' and ''c =  a<sup>2</sup>'', then  
 
:{{Example|1=<div>If ''a = 2'' and ''c =  a<sup>2</sup>'', then  
:* <code>Text[c, true]</code> returns the text "4" and  
+
:* <code>Text[c, true]</code> returns the text ''"4"'' and  
:* <code>Text[c, false]</code> returns the text "''a<sup>2</sup>''"</div>}}
+
:* <code>Text[c, false]</code> returns the text ''"a<sup>2</sup>"''.</div>}}
; Text[Object, Point]: Returns the formula for the object as a text object at the position of the given point.
+
; Text[ <Object>, <Point> ]
 +
: Returns the formula for the object as a text object at the position of the given point.
 
: {{Example|1=<code>Text["hello", (2, 3)]</code> returns the text ''hello'' at the position ''(2, 3)''.}}
 
: {{Example|1=<code>Text["hello", (2, 3)]</code> returns the text ''hello'' at the position ''(2, 3)''.}}
; Text[Object, Point, Boolean]: Returns the formula for the object as a text object at the position of the given point. The Boolean variable determines if values are substituted for variables (''true'') or if variable names are shown in the text (''false'').
+
; Text[ <Object>, <Point>, <Boolean for Substitution of Variables> ]
; Text[Object, Point, Boolean substitute,Boolean LaTeX]:
+
: Returns the formula for the object as a text object at the position of the given point. The Boolean variable determines if values are substituted for variables (''true'') or if variable names are shown in the text (''false'').
 +
: {{Example|1=If ''a = 2'' and ''c = a<sup>2</sup>'', then <code>Text[c, (2, 1), true]</code> returns the text ''"4"'' at the position ''(2, 1)''.}}
 +
; Text[ <Object>, <Point>, <Boolean for Substitution of Variables>, <Boolean for LaTeX formula> ]
 
: Returns the formula for the object as a text object at the position of the given point. First Boolean variable determines if values are substituted for variables (''true'') or if variable names are shown in the text (''false'').  If the second Boolean variable is ''true'', the result is rendered using [[LaTeX]].
 
: Returns the formula for the object as a text object at the position of the given point. First Boolean variable determines if values are substituted for variables (''true'') or if variable names are shown in the text (''false'').  If the second Boolean variable is ''true'', the result is rendered using [[LaTeX]].
 +
: {{Example|1=If ''a = 2'' and ''c = a<sup>2</sup>'', then <code>Text[c, (2, 1), true, true]</code> returns the text ''"4"'' at the position ''(2, 1)'' using LaTeX.}}

Revision as of 15:45, 9 August 2013



Text[ <Object> ]
Returns the formula for the object as a text object.
Note: By default, values are substituted for variables.
Example: If a = 2 and c = a2, then Text[c] returns the text "4".
Text[ <Object>, <Boolean for Substitution of Variables> ]
Returns the formula for the object as a text object. The Boolean variable determines if values are substituted for variables (true) or if variable names are shown in the text (false).
Example:
If a = 2 and c = a2, then
  • Text[c, true] returns the text "4" and
  • Text[c, false] returns the text "a2".
Text[ <Object>, <Point> ]
Returns the formula for the object as a text object at the position of the given point.
Example: Text["hello", (2, 3)] returns the text hello at the position (2, 3).
Text[ <Object>, <Point>, <Boolean for Substitution of Variables> ]
Returns the formula for the object as a text object at the position of the given point. The Boolean variable determines if values are substituted for variables (true) or if variable names are shown in the text (false).
Example: If a = 2 and c = a2, then Text[c, (2, 1), true] returns the text "4" at the position (2, 1).
Text[ <Object>, <Point>, <Boolean for Substitution of Variables>, <Boolean for LaTeX formula> ]
Returns the formula for the object as a text object at the position of the given point. First Boolean variable determines if values are substituted for variables (true) or if variable names are shown in the text (false). If the second Boolean variable is true, the result is rendered using LaTeX.
Example: If a = 2 and c = a2, then Text[c, (2, 1), true, true] returns the text "4" at the position (2, 1) using LaTeX.
© 2024 International GeoGebra Institute