org.symbian.tools.wrttools.doc.WRTKit/html/WRTKit_Control_Class-GUID-6ddb8154-3fed-40fc-b282-85e6d3ad494f.html
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en" xml:lang="en">
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<meta name="copyright" content="(C) Copyright 2005" />
<meta name="DC.rights.owner" content="(C) Copyright 2005" />
<meta content="concept" name="DC.Type" />
<meta name="DC.Title" content="WRTKit Control Class" />
<meta scheme="URI" name="DC.Relation" content="WRTKit_API_Reference-GUID-00e47c27-0a1a-443f-ae85-cf3381635170.html" />
<meta content="XHTML" name="DC.Format" />
<meta content="GUID-6DDB8154-3FED-40FC-B282-85E6D3AD494F" name="DC.Identifier" />
<meta content="en" name="DC.Language" />
<link href="commonltr.css" type="text/css" rel="stylesheet" />
<title>
WRTKit Control Class</title>
</head>
<body id="GUID-6DDB8154-3FED-40FC-B282-85E6D3AD494F"><a name="GUID-6DDB8154-3FED-40FC-B282-85E6D3AD494F"><!-- --></a>
<h1 class="topictitle1">
WRTKit Control Class</h1>
<div>
<div class="section"><h2 class="sectiontitle">
Description</h2>
<p>
The Control class is an abstract base class for user interface controls.
Don't instantiate Control directly but rather one of its subclasses.
</p>
</div>
<div class="section"><h2 class="sectiontitle">
Inherits from</h2>
<p>
<a href="WRTKit_UIElement_Class-GUID-37b82f75-720c-4f54-9769-cda18453ffa3.html">
UIElement</a>
</p>
</div>
<div class="section"><h2 class="sectiontitle">
Events</h2>
<br /><ul>
<li>
<p>
FocusStateChanged</p>
<p>
This event is fired when focus state of the control has changed.
</p>
</li>
<li>
<p>
HoverStateChanged</p>
<p>
This event is fired when hover state of the control has changed.
</p>
</li>
</ul>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="WRTKit_API_Reference-GUID-00e47c27-0a1a-443f-ae85-cf3381635170.html">WRTKit API Reference</a></div>
</div>
</div>
<div class="nested1" id="GUID-CF6C59C7-1FB2-4B30-85F1-31818B519739"><a name="GUID-CF6C59C7-1FB2-4B30-85F1-31818B519739"><!-- --></a>
<h2 class="topictitle2">
getCaption()</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[String] Control.getCaption(void)</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
Retrieves the current caption of the control.
The value is an XHTML string.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Arguments</h3>
<p>
This method does not take any arguments.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Return value</h3>
<p>
The current caption of the control or null if the control doesn't have a caption.
</p>
</div>
</div>
</div>
<div class="nested1" id="GUID-2746C552-8BFB-4C81-8790-3CAC42E6D73A"><a name="GUID-2746C552-8BFB-4C81-8790-3CAC42E6D73A"><!-- --></a>
<h2 class="topictitle2">
setCaption()</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[void] Control.setCaption(String caption)</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
Sets the caption for the control. If null is specified as the caption
then the caption is removed (entirely hidden) for the control.
The value is an XHTML string.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Arguments</h3>
<br /><ul>
<li>
<p>
caption</p>
<p>
The new caption for the control or null for no caption.
</p>
</li>
</ul>
</div>
<div class="section"><h3 class="sectiontitle">
Return value</h3>
<p>
This method does not return a value.
</p>
</div>
</div>
</div>
<div class="nested1" id="GUID-CC9D9EA5-DCD8-4EBE-9FAC-A3C87C845AB2"><a name="GUID-CC9D9EA5-DCD8-4EBE-9FAC-A3C87C845AB2"><!-- --></a>
<h2 class="topictitle2">
isEnabled()</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[Boolean] Control.isEnabled(void)</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
Retrieves the enabled state of the control.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Arguments</h3>
<p>
This method does not take any arguments.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Return value</h3>
<p>
The current enabled state of the control.
</p>
</div>
</div>
</div>
<div class="nested1" id="GUID-F336AA4D-EDFF-4109-A7C5-A6C0AF0DCC11"><a name="GUID-F336AA4D-EDFF-4109-A7C5-A6C0AF0DCC11"><!-- --></a>
<h2 class="topictitle2">
setEnabled()</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[void] Control.setEnabled(Boolean state)</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
Sets the enabled state for the control.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Arguments</h3>
<br /><ul>
<li>
<p>
state</p>
<p>
The new enabled state for the control; true to enable, false to disable.
</p>
</li>
</ul>
</div>
<div class="section"><h3 class="sectiontitle">
Return value</h3>
<p>
This method does not return a value.
</p>
</div>
</div>
</div>
<div class="nested1" id="GUID-1667AEC9-B037-4A45-A89E-38369F63CCD0"><a name="GUID-1667AEC9-B037-4A45-A89E-38369F63CCD0"><!-- --></a>
<h2 class="topictitle2">
isFocusable()</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[Boolean] Control.isFocusable(void)</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
Retrieves the focusable state of a control. The focusable state tells
whether the control can be focused or not. E.g. a label control cannot
be focused because it does not have any interactive action to perform.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Arguments</h3>
<p>
This method does not take any arguments.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Return value</h3>
<p>
The focusable state of the control.
</p>
</div>
</div>
</div>
<div class="nested1" id="GUID-954AA9E7-4239-432E-A1D9-66CDD75F274E"><a name="GUID-954AA9E7-4239-432E-A1D9-66CDD75F274E"><!-- --></a>
<h2 class="topictitle2">
isFocused()</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[Boolean] Control.isFocused(void)</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
Retrieves the focused state of the control.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Arguments</h3>
<p>
This method does not take any arguments.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Return value</h3>
<p>
The current focused state of the control.
</p>
</div>
</div>
</div>
<div class="nested1" id="GUID-B8FD2E60-F202-4089-A253-11B765EF0C41"><a name="GUID-B8FD2E60-F202-4089-A253-11B765EF0C41"><!-- --></a>
<h2 class="topictitle2">
setFocused()</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[void] Control.setFocused(Boolean state)</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
Sets the focused state for the control. Note that it's not always possible
to carry out the request to focus a control. E.g. a control might not be
visible or the focus might be locked to another control.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Arguments</h3>
<br /><ul>
<li>
<p>
state</p>
<p>
The new focused state for the control; true to focus, false to blur.
</p>
</li>
</ul>
</div>
<div class="section"><h3 class="sectiontitle">
Return value</h3>
<p>
This method does not return a value.
</p>
</div>
</div>
</div>
<div class="nested1" id="GUID-DAB168FA-2ED0-4733-AE59-ABC4B7F0AFB2"><a name="GUID-DAB168FA-2ED0-4733-AE59-ABC4B7F0AFB2"><!-- --></a>
<h2 class="topictitle2">
updateStyleFromState()</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[void] Control.updateStyleFromState()</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
Called to let the control update its style to match its internal state.
The method doesn't need to be called manually as the toolkit takes care of
calling it whenever the state of a control changes. Override this method
if you wish to implement custom styling for a control. Typically using
CSS rules will be sufficient for customizing looks so only use this method
when CSS is insufficient.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Arguments</h3>
<p>
This method does not take any arguments.
</p>
</div>
<div class="section"><h3 class="sectiontitle">
Return value</h3>
<p>
This method does not return a value.
</p>
</div>
</div>
</div>
<div class="nested1" id="GUID-B790F37D-A86B-47F1-80CC-950C4653BEA2"><a name="GUID-B790F37D-A86B-47F1-80CC-950C4653BEA2"><!-- --></a>
<h2 class="topictitle2">
view</h2>
<div>
<div class="section"><h3 class="sectiontitle">
Syntax</h3>
<pre>
[View] Control.view</pre>
</div>
<div class="section"><h3 class="sectiontitle">
Description</h3>
<p>
The view property references the view that the control is attached to.
If the control has not been attached to any view then the property is null.
</p>
</div>
</div>
</div>
</body>
</html>