This document is for use with the Nokia Mobile Internet Toolkit. Reproduction, transfer, distribution or
storage of part or all of the contents in this document in any form without the prior written permission
of Nokia is prohibited.
, Nokia Mobile Internet Toolkit, and the Nokia Connecting People logo are trademarks or registered
Nokia
trademarks of Nokia Corporation. Other product and company names mentioned herein may be trademarks or
trade names of their respective owners.
Java and all Java-based trademarks and logos are trademarks or registered trademarks of Sun
Microsystems, Inc
.
Nokia operates a policy of on-going development. Nokia reserves the right to make changes and
improvements to any of the products described in this document without prior notice.
UNDER NO CIRCUMSTANCES SHALL NOKIA BE RESPONSIBLE FOR ANY LOSS OF DATA OR
INCOME OR ANY SPECIAL, INCIDENTAL, CONSEQUENTIAL OR INDIRECT DAMAGES
HOWSOEVER CAUSED.
THE CONTENTS OF THIS DOCUMENT ARE PROVIDED "AS IS". EXCEPT AS REQUIRED BY
APPLICABLE LAW, NO WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS FOR A PARTICULAR PURPOSE, ARE MADE IN RELATION TO THE ACCURACY,
RELIABILITY OR CONTENTS OF THIS DOCUMENT. NOKIA RESERVES THE RIGHT TO
REVISE THIS DOCUMENT OR WITHDRAW IT AT ANY TIME WITHOUT PRIOR NOTICE.
The availability of particular phone products may vary by region. Please check with the Nokia dealer
nearest to you.
Visit Forum Nokia (http://www.forum.nokia.com)
, the site designed for developers using technologies
This guide describes how to use the Nokia Mobile Internet Toolkit 4.1.
Audience
Read this guide if you are a developer of Push, MMS, and DRM messages or of web content for
cell phones.
Standards Support
Nokia Mobile Internet Toolkit 4.1, supports WAP and other standards maintained by the Open
Mobile Alliance (OMA), as well as other standards maintained by other organizations.
Typographical Conventions
The following typographical conventions are used in this guide:
NotationExplanation
Courier
Italic
BoldNames of Windows menus, commands, buttons, and icons
URL link
Nokia Mobile Internet Toolkit User’s Guide5
Text that you enter (as opposed to system prompts and responses)
•File paths
•Commands
•Program code
•Names of books, documents, and new terminology
Active link
Related Documents
Specifications, that are created and maintained by the Open Mobile Alliance and are freely
available at http://openmobilealliance.org.
Assorted documents aboutmessaging technologies are freely available from http://
www.forum.nokia.com/.
Numerous specifications of interest to mobile content developers, notably those relating to
XHTML Mobile Profile and CSS, are published by the World Wide Web Consortium (W3C). You
may access these at http://www.w3.org/
Introduction
6Nokia Mobile Internet Toolkit User’s Guide
Getting Started
Nokia Mobile Internet Toolkit (NMIT) consists of a set of editors that you can use to learn how
tto create various types of mobile Internet content. NMIT lets you display this content on
multiple phone SDKs.
Phone SDKs are installed separately. NMIT detects installed, supported phone SDKs at startup
and lists these in its
phone SDK by simply clicking a
Many NMIT editors are used for creating XML-based content types defined by Document Type
Defintions (DTDs). These editors employ content validation to check content against a DTD, and
they provide features for easily selecting elements and attributions for insertion based on current
cursor position. In addition, NMIT provides a DTD Manager through which you can import new
DTDs for use by NMIT editors.
This chapter discusses the following topics:
Features
Launching NMIT
SDK Control Panel
. You can display content you author on any supported
Show
button within an editor.
Menus
Navigate Using Keyboard Shortcuts
Nokia Mobile Internet Toolkit User’s Guide7
Getting Started
Features
Major features of NMIT include:
•A set of editors for creating and editing mobile Internet content. These are all
accessible using the File>New or File>Open command. Most editors enable the
immediate processing and display of content on a phone SDK by pressing a button
(Show or Push) within the editor. The following table briefly describes these editors.
NMIT Editors
Browsing EditorsDescription
WML 1.3 Deck
WML Script
WBMP Image
XHTML-MP
XHTML-MP+CHTML
CSS
Select DTD From ListCreate a document based on a selected system DTD, that is,
Create a Wireless Markup Language (WML) document.
Supports the WML 1.3 DTD, which conforms to the June
2000 WAP specification. Creation of WML 1.2 and 1.1
documents is also supported.
Create WMLScript content. WMLScript is a derivative of
ECMA Script and is used to add programmatic logic to a
WML deck, for example, calculations.
Create a Wireless Bitmap (WBMP) image. Similar to most
image editors, the WBMP editor enables the creation and
editing of WBMP images, as well as conversion of existing
images from GIF and JPEG formats to WBMP format.
Create an XHTML document based on the XHTML Mobile
Profile DTD.
Create an XHTML document based on the XHTML Mobile
Profile DTD with additional element and attributes taken
from Compact HTML.
Create a Cascading Style Sheet (CSS). The CSS contains
formatting style definitions that will be applied to the
elements specified in an XHTML document.
a DTD from a built-in list or one you created yourself.
Push Content EditorsDescription
Service Indication (SI)
Editor
Service Loading (SL)
Editor
Cache Operation (CO)
Editor
8Nokia Mobile Internet Toolkit User’s Guide
Create a Service Indication Push message, which is sent to
notify a user of the availability of new content.
Cre ate a Serv ice Lo ading Push m essag e, whi ch is sen t to force
a user agent running on the client device to download new
content (without notifying the user).
Create a Cache Operation Push message, which is sent to
invalidate specific content in the user agent cache (thus
forcing a reload of content the next time the user requests
that content).
NMIT Editors
Features
Multipart Message
Editor
Messaging EditorsDescription
MMS Wizard
MMS Message Editor
SMIL Editor
Deployment EditorsDescription
DRM Editors
Rights Editor
Create a multipart message, which is a kind of Push message
consisting of more than one part, each of which is separately
processed by the user agent. The editor enables the
incorporation and ordering of already existing parts (files)
into a single multipart message.
Create a Multimedia Messaging file consisting of one or
more parts, each part consisting of text, image, or audio
content.
Create or edit an MMS Message. Major features enable you
to add, delete, or rearrange media parts; edit MMS headers
and individual Part headers; and push the message to
selected phone SDKs.
Create a Synchronized Multimedia Integration Language file
(SMIL and SMIL 3GPP), for specifying the presentational
options of an MMS message.
Create a DRM message with content and rights to it.
Edit DRM rights in an XML editor.
Download Descriptor
Editor
Create a Download Descriptor, which describes the content
so a phone user can determine whether the content can be
loaded on the phone.
•An SDK Control Panel from which you can select one or more installed phone SDKs
upon which to display content from an editor or from the Internet. The panel is a tab
in the main window and is shown below. See the chapter titled Working With SDKs
for a complete description.
Nokia Mobile Internet Toolkit User’s Guide9
Getting Started
•Several sample applications you can use as aids in developing your own content.
These include the content types WML, XHTML, Push, and MMS and are readily
available through the File>Open menu, through the Bookmarks button (see above
figure), or in the directory:
•Ease of Use Features, described in the table below:
Ease of Use FeatureDescription
Pop-Up MenusMany NMIT commands and functions are accessible by clicking
<NMIT-installation-directory>\samples
the right mouse button.
Right-clicking within a window area but not on an individual
item will generally display a popup menu of window-level
commands, such as Close or Tear of f .
Right-clicking on an individual item displays commands relevant
to that item. For example, right-clicking on an XHTML
document displays commands for revalidating the document and
for showing the document on phone SDKs. If there are no
commands particularly relevant to an individual item, NMIT
usually displays window-level commands in the popup menu.
.
Tool TipsTool tips are pop-up text describing the function of an active
control. Throughout the NMIT interface, resting the cursor on
an active control such as a button or drop-down lists displays a
tool tip.
Documentation The User’s Guide (this manual) is provided in PDF format for
viewing using Adobe Acrobat.
Keyboard ShortcutsNMIT makes navigation and selection functions available
through keyboard and keypad presses for those who prefer the
keyboard to the mouse. These are described in the section titled
Navigate Using Keyboard Shortcuts
Independent WindowsYou can keep multiple documents open and visible
simultaneously by "tearing off" a document, that is, detaching it
from the main NMIT window so it is an independent window. As
an independent window it can be sized, moved, and minimized
independently.
To tear off a document, right-click in the document window and
choose the Tea r O ff pop-up menu option.
To put a torn off document back into the NMIT main window as
a tab page, right-click in the document window and choose the
Put Back pop-up menu option.
.
Editor PreferencesBefore using an NMIT editor, you may wish to set the available
editor preferences such as line numbering, auto-validation, and
show warnings.
10Nokia Mobile Internet Toolkit User’s Guide
Launching NMIT
Launching NMIT
You can launch NMIT from the Windows
Start
menu or from the command line.
Launching NMIT From the Windows Start Menu
To launch NMIT from the Windows
Start>Programs>Nokia Developer Tools>Nokia Mobile Internet Toolkit>NMIT4.1
Start
menu, choose:
Launching NMIT From a Command Line
You can launch NMIT by directly executing a
is useful if you wish to launch NMIT programmatically, for example, from within another
application.
Launching from the command line is also useful for specifying that one or more files be opened
upon launch. These files will be opened in the appropriate NMIT editor, based on file type.
Additionally, for all text files listed on the command line, you can specify that they be opened
using any of the supported character encodings. In this case, the files will be read using the
specified encoding, unless encoding information specified in the content itself (XML-based
content only) overrides the encoding you specify.
If you have accepted the NMIT default installation location, the location of the NMIT executable
is:
syntax statement, substitute the full path name, such as the above default path, for
Toolkit.exe [-argname argvalue ...] [file ...]
.exe
or
.jar
file. Launching from a command line
.
In the following
Toolkit.exe
.
An argument is identified by a required hyphen (-) preceding the argument name. For arguments
that accept a value, the value follows the name and is separated by a space. If multiple arguments
are specified, a space ( ) is required between each, and between an argument and any specified file
parameters. The following are the permitted arguments:
-enc
This argument specifies that any text files listed on the command line be
imported into the appropriate NMIT editor (based on file type) using the
specified character encoding.
This argument must be specified on the command line prior to any files. For
example, the following command launches NMIT, opens
WML editor and
the
utf-16
Toolkit.exe -enc utf-16 file1.wml file2.xhtml
Character encodings supported by NMIT are listed in the Default Input
Text Encoding list box within the Toolkit Preferences dialog
(Edit>Preferences). You may enter any of these encodings as a command
line argument.
character encoding:
file2
in the XHTML editor, and reads both files using
file1
in the
When you use character encoding as an argument value, the following rules apply:
Nokia Mobile Internet Toolkit User’s Guide11
Getting Started
•The encoding in the file takes precedence over the encoding in Preferences or the
command line.
•If the file does not specify a character encoding, the encoding in the command line
argument takes precedence over the encoding specified in Preferences.
•If no encoding is specified in the file or on the command line, the Default Input
encoding value in Preferences is used.
You can also launch NMIT from a command line by executing its
.jar
file. Assuming you
accepted the default NMIT installation directory, do the following:
If NMIT is not currently running, it will be started. If it is already running, the content is
displayed in the running NMIT rather than in another instance of NMIT.
Upon launch, the NMIT
Wel co me
tab is displayed along with the
SDK Control Panel
:
Wel co me
The
Welc om e
tab provides an overview of NMIT functions. You can drag the bar so that the
section does not display.
Menus
This chapter describes the following six NMIT main menu commands and their submenus.
File MenuEdit MenuWindows Menu
Tools MenuHelp Menu
12Nokia Mobile Internet Toolkit User’s Guide
File Menu
The
File
menu provides these options:
File Menu Options
NewDisplays the Availa ble Co nte nt Type s dialog from which you can choose
a content type for the file you wish to create.
After you select the content type and choose OK, NMIT opens the
appropriate editor, displaying a default template for the content type.
OpenDisplays the Open file for editing dialog from which you can navigate to
an existing file that you wish to edit.
NMIT opens the appropriate editor for the selected file based on the file
type.
CloseCloses the current document and displays the next open document in the
NMIT tab order (if there are other open documents).
SaveIn an NMIT Editor window, saves an already named file. If the file is
untitled, you are prompted for a file name.
Menus
Save AsIn an NMIT Editor window, opens the Save as dialog into which you can
type a file name for the file you wish to save. By default, NMIT supplies a
file extension for the file based on the content type.
Save as Template...In an NMIT Editor window, lets you save the current content so that the
editor is initialized with that content when you next create a new file of
the same Content Type.
To restore a default template, quit NMIT and then delete the template
you saved from:
Template names are the icon label prepended by
the Content Type.
When you restart NMIT and create new content with the editor, the
editor then opens with the default template.
Print(Text editors only) Opens the Print dialog from which you can print the
current document.
Print to HTML...Opens the Save As dialog which enables you to save the current document
in publishable HTML format (text editor only). When such a document
is subsequently opened in a browser, it is displayed as it is displayed within
an NMIT editor, showing elements and attributes, proper syntax, and
color coding.
This format is useful for publishing code for review by other content
developers or for creating online documentation for programming code.
New
and appended with
.
<various file
names>
ExitCloses NMIT and all the SDKs started from NMIT
Nokia Mobile Internet Toolkit User’s Guide13
Re-opens any of these most recently opened file names. Up to four files are
listed.
Getting Started
Edit Menu
Edit commands are selectively available or unavailable depending on the context.
Copy
, and
Paste
are generally available in Editor windows. Others, such as
Undo
Find, Cut,
and
unavailable if you have as yet taken no action. Unavailable commands are grayed out.
Edit Menu Options
UndoUndo the previous action.
Note that NMIT dynamically renames this menu item to reflect what its action
will be. For example, if you have performed a paste operation, the menu item is
renamed Undo addition. This item is grayed out if there is no previous action.
RedoDo the action that had previously been undone; that is, undo the last undo.
Note that NMIT dynamically renames this menu item to reflect what its action
will be. This item is grayed out if there is no previous action.
CutDelete the selected text and copy it to the Clipboard.
CopyCopy the selected text to the Clipboard.
PastePaste the contents of the Clipboard at the cursor insertion point.
FindOpens the Find/Replace Text dialog in which you can specify text to find (and
optionally replace) in the current editor window.
Windows Menu
Redo
are
The
Windows
menu enables you to view all open documents and provides options for selecting
which window is the active window and for tearing off or putting back the active window.
Windows Menu Options
<open
documents>
Tea r O ff
<current>
Displays a list of all open documents. Select an open document to bring that
document to the foreground for editing.
Tears off the active document from the NMIT main window, creating an
independent window (with a complete menu bar) that can be sized, moved,
and minimized independently. This function enables you to view multiple
documents simultaneously.
To put a torn off document back into the main NMIT window, choose the
Windows>Put Back menu item from the torn off window’s menu bar.
Both the tearing off and the putting back of document windows can also be
accomplished by right-clicking the mouse in a document window and then
choosing the desired option from the popup menu.
14Nokia Mobile Internet Toolkit User’s Guide
Tools Menu
The
Tools
menu provides these options:
Tools Menu Options
SDK Control PanelOpens the SDK Control Panel tab from which you can choose among
available phone SDKs to which you wish to send a document for display.
The use of this control panel is described in the chapter titled Wo rk in g
With SDKs.
DTD ManagerOpens the DTD Manager, an NMIT component that enables you to
register additional DTDs for use with NMIT content editors (see DTD
Manager).
WAP Gat ewayLaunches Nokia WAP Gateway Simulator (NWGS) if installed on your
computer. NWGS is a single-user WAP Gateway based on the multiuser Nokia Activ Server.
In order to browse the Internet using a phone SDK, the phone SDK
must be configured to use NWGS or an external WAP gateway. If the
former, NWGS must be running. This menu option is provided for
convenience in launching NWGS.
Menus
PreferencesOpens the Preferences
dialog, described below.
Nokia Mobile Internet Toolkit User’s Guide15
Getting Started
Preferences
Choose
pages
The
Tools>Preferences
General
General
Placement
to open the Toolkit Preferences dialog, which contains the two tab
and
Text Editors
.
tab provides settings arranged in the three regions:
, as shown below.
Startup, War ning s
, and
Ta b
General Tab Options
Startup
On Startup, re-open files that were open
on previous exit
On Startup, start previously running
SDKs
On Startup, /Start Nokia WAP Gateway
Server
Warnings
When checked, NMIT reopens files that were open
when you last exited from NMIT.
When checked, NMIT starts all the SDKs that were
running when you last exited from MIT.
When checked, NMIT starts the Nokia WAP
Gateway Simulator every time you start NMIT.
If checked, NMIT displays compilation errors in a
pop-up dialog box, as well as in the message area
below the editing window.
Unchecking this box disables pop-up display of
compilation error messages.
16Nokia Mobile Internet Toolkit User’s Guide
General Tab Options
Menus
If checked, NMIT displays a warning under these
conditions:
•The current WML or XHTML document you
show on a phone SDK exceeds the size you
specified in the bytes text entry field.
•The size of the compiled content of a WML file
saved in binary format exceeds the size you
specified in the bytes text entry field.
If unchecked, NMIT displays no warnings.
This field uses a drop-down list box displaying
several existing mobile devices and the size of largest
file that can be downloaded to the device.
You can choose from the list, or you can enter your
own value by selecting the existing value and then
typing in a new value.
MMS ignores this setting and uses size limits defined
for each SDK.
Tab Placement
To pPositions document tabs along the top of the display
window.
RightPositions document tabs to the right of the display
window.
BottomPositions document tabs along the bottom of the
display window.
LeftPositions document tabs to the left of the display
window.
Nokia Mobile Internet Toolkit User’s Guide17
Getting Started
The
and encoding to be used in the display of documents open in a text editor, and initial settings for
XML/CSS editors:
Tex t Ed it o r
tab provides settings that apply to all text editors in NMIT, including the font
Text Editor
FontSets the font to be used in the display of text within the content editing
region of all text editors. NMIT offers the two font options Default Font
and Arial Unicode MS, though the latter is offered only if this font is already
installed on your computer. Some differences between these are given below;
however, you should choose whichever you prefer.
The Default Font is a monospaced font: each character is of the same fixed
width. This is the NMIT default font, a sample of which is shown below:
The Arial Unicode MS font is a “richer” font than the NMIT default font
and contains support for many languages; however, it is not a monospace
font. It is recommended to choose this font if your content contains
characters from any Asian language. The following code snippet uses the
Arial Unicode MS font:
When you change a font, the change is seen in documents you open
thereafter; documents already open are unchanged.
18Nokia Mobile Internet Toolkit User’s Guide
Menus
Default Input
Text Encoding
Use this drop-down list to choose a text encoding that an NMIT text editor
will use as the default encoding when reading in a document that you have
chosen to open. Note the following:
•Whenever an XML-based document contains a statement specifying its
own encoding (the
charset
attribute in the XML prologue on the first
line), NMIT reads in the document using that encoding rather than the
encoding specified in the Default Input Text Encoding list.
•Some encodings have an identifying signature in the first few bytes. In
this case, NMIT may detect that the document uses a different
encoding and will then use the encoding it discovers rather than the one
you specified in the list.
•If the document was specified as a command line argument with the
enc
encoding, NMIT uses that encoding.
-
•If the Default Input Text Encoding does not match the encoding used at
the time the document was created, the document may appear garbled
or unreadable. In this case, close the document and re-open it using a
different input encoding. (See the section Preferences
for details on how
to do this.
•NMIT uses the UTF-8 encoding by default.
For additional information, see the section Displaying a Non-UTF-Encoded
Document on Phone SDKs.
XML/CSS Editors
If checked, line numbers are displayed along the left border in the text
editing areas of all the text-based editors.
If unchecked, no line numbers are displayed.
Line numbers in compile error reporting will be displayed even if this box is
unchecked.
If checked, NMIT’s text-based editors revalidate document content
automatically at five-second intervals after editing activity stops. This saves
you from having to revalidate manually using the Revalidate button in the
editor window. This is the default setting. Open files are automatically
revalidated, even if this box is unchecked.
If unchecked, automatic revalidation is disabled.
If checked, NMIT’s text-based editors validate the document content
against the DTD specified in the
DOCTYPE
declaration found within the
document content. In this case, the parser checks that all elements and
attributes are used in accordance with the rules specified in the DTD as well
as in accordance with the XML rules for creating “well formed’ content.
This is the default setting.
If unchecked, NMIT’s validating parser checks only for “well-formed”
XML-based content.
Nokia Mobile Internet Toolkit User’s Guide19
Getting Started
Help Menu
The
Help Menu Options
If checked, the element in which the cursor is currently positioned is
highlighted in a light background color.
If unchecked, no highlighting is used to identify current cursor position.
This is the default setting.
If checked, non-fatal parser warnings are displayed whenever NMIT’s
parser revalidates the document.
If unchecked (the default), no warnings are shown.
Errors are always shown no matter what the setting.
Help
menu provides options for accessing NMIT user guide information and release notes:
User’s Guide
(PDF)
Nokia Update
Manager
Release NotesDisplays the release notes accompanying this version of NMIT. These notes
About Mobile
Internet Toolkit
FeedbackLets you send any comments you have about this product to Nokia
Opens the
in Adobe Acrobat Reader.
Launches Nokia Update Manager, a small application that enables you to
easily download and install Forum Nokia software. An Internet connection
is required to use Update Manager.
include version information, changed features, and unresolved issues.
Opens the About Mobile Internet Toolkit dialog, which provides NMIT
version information.
Corporation if you have an active Internet connection.
Nokia Mobile Internet Toolkit 4.1 User’s Guide (this manual)
Navigate Using Keyboard Shortcuts
NMIT provides keyboard shortcuts you can use to navigate and perform operations. These are key
combinations that can be used in place of normal mouse operations and are particularly useful if
you prefer using the keyboard to using the mouse.
•NMIT Windows shortcuts. Use the Windows shortcut ALT+TAB to move input
focus from one window to another, for example, to move from the NMIT main
window to a “torn off” NMIT editor window. Within the Multipart Editor, use TAB
to move input focus from one header field to another. Use CTRL+TAB moves the
input focus between window elements such as controls or buttons that you may wish
to select.
•You can tell that buttons have the input focus by noting an indented rectangular
border; text-entry fields are highlighted.
20Nokia Mobile Internet Toolkit User’s Guide
Navigate Using Keyboard Shortcuts
•Menu item shortcuts. To choose a menu item, press the ALT key while
simultaneously pressing the letter that is underlined in the menu item name. Once a
menu is opened, you can select another item within that menu by pressing the ALT
key in combination with the UP or DOWN arrows and then choosing ENTER.
A key combination is executed by holding down the key preceding the plus sign (+) and then
pressing the key following the plus sign. In effect, pressing two keys simultaneously.
Keyboard Shortcuts for NMIT Windows
Key CombinationDescription
ALT+TABOn Windows operating systems, moves focus from one Windows process
to another. In NMIT, moves focus from the main NMIT window to a
phone SDK or to a torn-off NMIT window.
ALT+xOn the menu bar, opens the menu whose name contains an underlined x
(x
).
Within a menu, chooses the menu item whose name contains an
underlined x (x
TABWithin a window, navigates forward from one control or field to the next,
eventually looping back to the starting point. The current position (or
“focus”) is indicated by a dotted rectangle.
In an editing area, inserts a tab character.
).
CTRL+TABWithin a window, moves focus from inside an editor window to the control
buttons and fields on that window but outside the editing area.
SHIFT+TABWithin a window, navigates backward from one control or field to the
next, eventually looping back to the starting point. The current position
(or “focus”) is indicated by a dotted rectangle.
ENTEROn a button, executes either the default button function or the function
having the active focus.
In an editing area, enters a carriage return character.
ALT+ENTERWithin a window, displays the application menu allowing you to move,
size, resize, minimize, maximize, or close the window.
<space bar>On a button, executes the button function.
On a check box, pressing <space bar> checks the button if it is currently
unchecked or unchecks it if it is currently checked.
When focus is in an editing area, enters a space character.
<Left arrow>When a main menu item is open, moves the focus to the main menu item
to the left.
<Right arrow>When a main menu item is open, moves the focus to the main menu item
to the right.
<Up arrow>On a menu or one of its menu items, moves the focus to the previous item
on that menu.
Nokia Mobile Internet Toolkit User’s Guide21
Getting Started
Keyboard Shortcuts for NMIT Windows
Key CombinationDescription
<Down arrow>On a menu or one of its menu items, moves the focus to the next item menu
on that menu.
PgUpIn an editor window, scrolls one page up.
PgDnIn an editor window, scrolls one page down.
Sending comments to Nokia Corporation
You can send any comments you have about this product to Nokia Corporation if you have an
active Internet connection by selecting Help>Feedback. Selecting this option automatically opens
http://www.forum.nokia.com/feedback where you can enter your comme
nts.
22Nokia Mobile Internet Toolkit User’s Guide
Browsing Editors
This manual defines a
browsing
editor as an editor used to create content for display by the
browser application of a phone SDK. Note that phone SDKs also have inbox-type applications for
handling Push messages and MMS messages. You do not “browse” the Push and MMS content
types; these are delivered to you.
Browsers on many phone SDKs can display both WML and XHTML text documents, as well as
other content types that are referenced by or invoked within these documents, such as WBMP or
GIF images, or, in the case of WML documents, WML Scripts. All of these content types, then,
are destined for display or handling by the browser application of a phone SDK, and this manual
groups the editors for these content types together under the category “browsing editors.”
Within the category of browsing editors may be found a set of editors that employ a validating
parser to check that text content is valid. These
validating editor
s are designed for content that
(1) is XML-based and uses a DTD or (2) employs hierarchical text elements that can be validated
for syntax (such as CSS). The two NMIT browsing editors that are not validating editors are the
WML Script and WBMP Image editors. The following table summarizes these distinctions among
NMIT’s browsing editors.
Validating EditorValidatable Content Uses DTD
WML 1.3 Deck
XHTML-MP
XHTML-MP+CHTML
Ye sYe s
Ye sYe s
Ye sYe s
Select DTD From List...YesYes
CSS
WML Script
WBMP Image
Nokia Mobile Internet Toolkit User’s Guide23
Ye sN o
Ye sN o
NoNo
Browsing Editors
You can use any of the following methods to open a validating editor, once you have in mind the
content type you wish to create:
•Choose File>New and then select one of the following icons in the Available Content
Ty pe s dialog.
•Choose File>New, choose the Select DTD From List icon (in the left column below),
select the desired DTD from the list showing all currently installed DTDs, and then
choose the Open Editor button:
•Choose Tools>DTD Manager, select a DTD from the list (same list as in (2) above) in
the Available DTDs region, and choose Open Editor.
•Choose File>Open and then choose an existing file with one of the following types:
wml, wmls, xhtml, html,wbmp,gif,
or
css
.
Editors for structured content types are functionally similar in the editing facilities they provide.
For this reason, they are described together in the section titled Browsing Editors for Validatable
Content. The WBMP Image and WML Script Editors are described separately in the section titled
Other Browsing Editors.
Browsing Editors for Validatable Content
Recall that a distinction is made between validatable content that is based on a Document Type
Definition (DTD) and validatable content which is not. (CSS is the single content type that does
not use a DTD.)
This section discusses first the editing features common to all validating editors; secondly, those
features used only when editing DTD-based content types; and then concludes with separate
discussions of each validating editor.
24Nokia Mobile Internet Toolkit User’s Guide
Browsing Editors for Validatable Content
Validating editors are editors that operate on any of the following structured content types:
• WML 1.3 Deck
• XHTML-MP
• XHTML-MP+CHTML
• CSS
• SMIL Editor (The SMIL content type is DTD-based, and SMIL editor features are
identical to those of the browsing editors for text content except for the lack of a
Show button to display content on a phone SDK. It is discussed in the Messaging
Editors chapter instead of here because it is not used to create browsable content.)
• Any content type opened using the Select DTD From List menu option (File>New
and then the Browsing tab).
Editing Features For Validatable Text Content
This section describes editing features for validating editor.
Editor Window Layout
The following figure shows the major regions in a validating editor:
Text Editing
Region
Message
Region
Active
Buttons
Note the following with respect to the above figure:
•Enter text in the text editing region. The NMIT editor displays a template for the
content type you have chosen when you create a new file.
•Use the side panel to insert valid attributes for the element highlighted by the cursor
in the text editing region and to modify attribute values.
Side Panel
Document
Size
Cursor
Position
Document
Encoding
•The message region displays validation messages when you save, Show, or Va li d a te a
document.
•Use the active buttons to validate content, show the document on phone SDKs, or set
editing options.
Nokia Mobile Internet Toolkit User’s Guide25
Browsing Editors
•The document summary displays details about the current document.
Initial Content of the Document Editing Region
Each of NMIT’s supported XML-based content types has an associated template. Therefore,
when you open an XML-based content type, the editor is initialized with the associated document
template. It is within this template that you begin entering your content. All required elements are
already inserted in the editor display, and comments suggest where you might wish to add various
new elements.
For an NMIT editor to open an XML-based content type, a unique template for that content type
must be installed. NMIT does provide a template file for the pre-installed DTD-based content
types. If you wish to install your own DTD, you must provide an associated template file or have
NMIT auto-generate a template file. These operations are performed using NMIT’s DTD
Manager.
Note that when you open the CSS text editor, which is not XML-based, the text editing region of
the editor window displays a sample CSS style sheet. This is helpful in that it shows proper syntax
and it may already include tags that you had planned to use.
Color Coding
A validating editor automatically differentiates among recognized data entered. For example,
element names are displayed in blue; attribute names, in red; attribute values, in gray; and so on.
This makes it easy to visually “parse” the displayed content. Note that colors might vary
depending on the configuration of your monitor.
Mouse Operations
The following table describes the possible mouse operations on text in the text editing region:
Single click• Sets the insertion point.
•Upon an element name, displays permissible attributes in the side
panel.
•Upon an attribute name, highlights that attribute in the side panel.
Double click•Selects a word, where a word consists of the characters bounded by
space or special characters such as the “<“ and “>”.
•Upon element or attribute names, also highlights these in the side
panel.
Triple clickSelects an entire line.
26Nokia Mobile Internet Toolkit User’s Guide
Browsing Editors for Validatable Content
Right clickDisplays a pop-up menu, whose options vary depending upon whether the
document content type is XML-based or CSS. For example:
RIGHT-CLICKON DTD-BASED CONTENT
XMLDisplays permissible attributes that can be inserted at the cursor position.
See the next section titled XML Element and Attribute Insertion Features
UndoUndoes the previous text editing operation.
RedoPerforms again the last text editing operation.
CutCuts the selected text to the Clipboard.
Right-Click on CSS Content
.
CopyCopies the selected text to the Clipboard.
PastePastes the contents of the Clipboard at the insertion point.
Show on
Phone SDKs
RevalidateFor an XML-based document, checks that the document is well-formed
CloseCloses the document. You will be prompted to save as yet unsaved
Tea r O ffRemoves the document from the NMIT main window and places it in a
For XML-based documents only, displays the current document on the
currently running phone SDKs. Only phone SDKs you have launched
using the SDK Control Panel will receive the document content.
Because CSS documents cannot be independently displayed, this option is
unavailable for CSS documents.
(correct syntax) and strictly conforming to the DTD.
For a CSS document, checks that the document is well-formed (correct
syntax).
documents.
separate, independent window.
XML Element and Attribute Insertion Features
When editing an XML-based document, you need to know which elements, if any, are valid child
elements of any given element. As well, you need to know which are the valid attributes that may
be inserted within an element. Then, once you have determined which element or attribute you
would like to insert, it is helpful to have these inserted for you automatically, using correct syntax
and spacing. NMIT provides the following features in support of this:
•XML popup menu option
•CRL+K key combination
Nokia Mobile Internet Toolkit User’s Guide27
Browsing Editors
•Side panel
All of these features are available for XML-based documents; however, the XML popup menu is
not available for CSS documents. XML-based documents must be valid, however, because menu
options displayed are derived from the rules inherent in the DTD. You must successfully revalidate
your document before using these automatic insertion features because revalidation maps the
cursor text position (where the item gets inserted) to the XML logical structure of the document.
To use any of the above features, first position the cursor by clicking within the current document.
For example, in the following figure, right-clicking on the
displays a popup menu within which the top
when selected. At the same time, legal attributes of the
submenu and in the side panel at the far right:
Right-Click on <card>
element or press CTRL+K
<card>
XML
menu option changes to
<card>
<card> attributes displayed
in sub-menu
element in the document
<card> Attributes
element are displayed both in a
<card> attributes displayed in
side panel
Note that pressing
right-clicking and choosing the
CTRL+K
within the
XML
submenu option.
<card>
element results in the same popup menu as does
To insert an attribute: (1) simply choose it from the submenu using the mouse or (2) use the Up
and Down arrow navigation keys to highlight it and then choose
class
in the figure above, choosing the
occurs within the opening and closing brackets of the
attribute inserts the string
<card>
Enter
class=“ ”
element.
. So, in the example shown
and the insertion
Both the XML menu and CTRL+K functions operate with sensitivity to cursor position. In the
following example, the
below the line containing the
position is outside of the opening and closing brackets of the
would be appropriate) but is inside of the opening
XML
menu option is selected with the cursor position on the blank line
<card>
element shown in the earlier figure. In this case, the cursor
<card>
<card>
and closing
element (where attributes
</card>
tags where child
28Nokia Mobile Internet Toolkit User’s Guide
Loading...
+ 120 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.