Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 24 additions & 28 deletions content/doc/flex/using/flx_mxml_mx.html
Original file line number Diff line number Diff line change
Expand Up @@ -88,10 +88,9 @@ <h3 class="topictitle3">Using Spark and MX component sets</h3>
the MX components. </p>

<p>The MX and Spark component sets contain many of the same components.
For example, both component sets defines a Button control, TextInput
control, and List control. However, while you can use MX components
For example, both component sets define Button, TextInput, and List controls. However, while you can use MX components
to perform most of the same actions that you can perform by using
the Spark components, it's best to you use the Spark components
the Spark components, it's best to use the Spark components
when possible. </p>

</div>
Expand Down Expand Up @@ -250,9 +249,7 @@ <h3 class="topictitle3">Compiling MXML to SWF Files</h3>


<div>
<p>You comple MXML files into SWF files. </p>

<p>You can deploy
<p>After you compile your MXML files into SWF files, you can deploy
your application as a compiled SWF file or as a SWF file included in
an AIR application. </p>

Expand All @@ -271,7 +268,7 @@ <h3 class="topictitle3">Compiling MXML to SWF Files</h3>
<p>For more information on wrappers, see <a href="flx_wrapper_wr.html#WS2db454920e96a9e51e63e3d11c0bf69084-7ecf_verapache">Creating
a wrapper</a>.</p>

<p>Flex also provides a command-line MXML compiler, mxmlc, that
<p>Flex provides a command-line MXML compiler, mxmlc, that
lets you compile MXML files. You can use mxmlc to compile hello.mxml
from a command line, as the following example shows:</p>

Expand All @@ -280,8 +277,8 @@ <h3 class="topictitle3">Compiling MXML to SWF Files</h3>

<p>In this example, <em>flex_install_dir</em> is the Flex installation
directory, and <em>app_dir</em> is the directory containing hello.mxml.
The resultant SWF file, hello.swf, is written to the same directory
as hello.mxml.</p>
The resulting SWF file, hello.swf, is written to the directory
where hello.mxml is.</p>

<p>For more information about mxmlc, see <a href="flx_compilers_cpl.html#WS2db454920e96a9e51e63e3d11c0bf69084-7ffd_verapache">Flex
compilers</a>. </p>
Expand All @@ -296,13 +293,13 @@ <h3 class="topictitle3">The relationship of MXML tags to


<div>
<p>Flex is implemented as an ActionScript class library. That
class library contains components (containers and controls), manager
<p>Flex is implemented as an ActionScript class library that
contains components (containers and controls), manager
classes, data-service classes, and classes for all other features.
You develop applications by using the MXML and ActionScript languages
with the class library. </p>

<p>MXML tags correspond to ActionScript classes or properties of
<p>MXML tags correspond to ActionScript classes, or properties of
classes. Flex parses MXML tags and compiles a SWF file that contains
the corresponding ActionScript objects. For example, Flex provides
the ActionScript <a href="https://flex.apache.org/asdoc/spark/components/Button.html" target="_blank">Button</a> class that
Expand Down Expand Up @@ -346,7 +343,7 @@ <h3 class="topictitle3">Understanding the structure of
Flex, you can divide your application into separate MXML files and
ActionScript files, where each file corresponds to a different module.
By dividing your application into modules, you provide many benefits,
including the following:</p>
including:</p>

<dl>

Expand Down Expand Up @@ -379,7 +376,7 @@ <h3 class="topictitle3">Understanding the structure of
<p>In Flex, a module corresponds
to a custom component implemented either in MXML or in ActionScript.
These custom components can reference other custom components. There
is no restriction on the level of nesting of component references
is no restriction on the levels of nesting of component references
in Flex. You define your components as required by your application.</p>

<p>You
Expand Down Expand Up @@ -407,8 +404,8 @@ <h2 class="topictitle2">Developing applications</h2>
Pages (JSP), Active Server Pages (ASP), and ColdFusion Markup Language
(CFML). Developing a useful Flex application is as easy as opening
your favorite text editor, typing some XML tags, saving the file,
requesting the file's URL in a web browser, and then repeating the same
process.</p>
requesting the file's URL in a web browser, and then repeating the
process for the next file you want.</p>

<p>Flex also provides tools for code debugging. For more information,
see <a href="flx_debugging_de.html#WS2db454920e96a9e51e63e3d11c0bf69084-7ffb_verapache">Command-line
Expand Down Expand Up @@ -489,10 +486,10 @@ <h3 class="topictitle3">Laying out a user interface using
&lt;/s:Application&gt;</pre>

<p>The <a href="https://flex.apache.org/asdoc/spark/components/List.html" target="_blank">List</a> control
and TabNavigator container are laid out side by side because they
and TabNavigator container appear side by side because they
are in an HGroup container. The controls in the TabNavigator container
are laid out from top to bottom because they are in a NavigatorContent
containers that use the VerticalLayout class.</p>
appear from top to bottom because they are in a NavigatorContent
container that uses the VerticalLayout class.</p>

<p>For more information about laying out user interface components,
see <a href="flx_components_cmp.html#WS2db454920e96a9e51e63e3d11c0bf69084-7fff_verapache">Visual components</a>.</p>
Expand All @@ -510,7 +507,7 @@ <h3 class="topictitle3">Adding user interface controls</h3>
such as <a href="https://flex.apache.org/asdoc/spark/components/Button.html" target="_blank">Button</a>, <a href="https://flex.apache.org/asdoc/spark/components/TextInput.html" target="_blank">TextInput</a>,
and <a href="https://flex.apache.org/asdoc/spark/components/ComboBox.html" target="_blank">ComboBox</a> controls.
After you define the layout and navigation of your application by
using container components, you add the user interface controls.</p>
using container components, you add the user interface controls to them.</p>

<p>The following example contains an HGroup (horizontal group) container
with two child controls, a TextInput control and a Button control.
Expand Down Expand Up @@ -690,7 +687,7 @@ <h3 class="topictitle3">Using XML namespaces</h3>

<p>This namespace includes
the RPC classes for the WebService, HTTPService, and RemoteObject
components and additional classes to support the RPC components.
components, and additional classes to support the RPC components.
These classes are included in the <samp class="codeph">mx:</samp> namespace,
but are provided as a convenience so that you can also reference
them by using the <samp class="codeph">s:</samp> namespace.</p>
Expand Down Expand Up @@ -928,7 +925,7 @@ <h3 class="topictitle3">Using MXML to trigger run-time
handling run-time events, in the event properties of MXML tags.
For example, the <samp class="codeph">&lt;s:Button&gt;</samp> tag has a <samp class="codeph">click</samp> event
property in which you can specify ActionScript code that executes
when the Button control is clicked at run time. You can specify
when a user clicks the Button control at run time. You can specify
simple event listener code directly in event properties. To use
more complex code, you can specify the name of an ActionScript function
defined in an <samp class="codeph">&lt;fx:Script&gt;</samp> tag.</p>
Expand Down Expand Up @@ -1084,7 +1081,7 @@ <h3 class="topictitle3">Using RPC services</h3>

<p>The following example shows an application that calls a web service
that provides weather information, and displays the current temperature
for a given ZIP code. The application binds the ZIP code that a
for a given United States ZIP code. The application binds the ZIP code that a
user enters in a TextInput control to a web service input parameter.
It binds the current temperature value contained in the web service
result to a TextArea control.</p>
Expand Down Expand Up @@ -1206,7 +1203,7 @@ <h3 class="topictitle3">Validating data</h3>
<div>
<p>Flex
includes a set of standard validator components for data such as
phone numbers, social security numbers, and ZIP codes. You can also
phone numbers, US Social Security numbers, and US ZIP codes. You can also
create your own custom validator.</p>

<p>In MXML, define validators in an <samp class="codeph">&lt;fx:Declarations&gt;</samp> tag.
Expand Down Expand Up @@ -1416,9 +1413,8 @@ <h3 class="topictitle3">Using effects</h3>
you apply effects as properties of a control or container. Flex
provides a set of built-in effects with default properties. </p>

<p>In MXML, define effects in an <samp class="codeph">&lt;fx:Declarations&gt;</samp> tag.
You use the <samp class="codeph">&lt;fx:Declarations&gt;</samp> tag to declare
non-visual components an MXML file. </p>
<p>In MXML, you use the <samp class="codeph">&lt;fx:Declarations&gt;</samp> tag to declare
non-visual components, like effects, an MXML file. </p>

<div class="p">The following example shows an application that contains a <a href="https://flex.apache.org/asdoc/spark/components/Button.html" target="_blank">Button</a> control
with its <samp class="codeph">click</samp> property set to use the <a href="https://flex.apache.org/asdoc/spark/effects/Resize.html" target="_blank">Resize</a> effect
Expand Down Expand Up @@ -1521,4 +1517,4 @@ <h3 class="topictitle3">Defining custom MXML components</h3>


</body>
</html>
</html>