Sun-microsystems Computer Accessories Manuel d'utilisateur

Naviguer en ligne ou télécharger Manuel d'utilisateur pour Accessoires pour ordinateurs Sun-microsystems Computer Accessories. Sun Microsystems Computer Accessories User Manual Manuel d'utilisatio

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 78
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 0
Sun Microsystems, Inc.
4159 Network Circle
Santa Clara, CA 95054
U.S.A. 650-960-1300
Basic Customization Guide
Wireless Toolkit, Version 2.1
Java
TM
2 Platform, Micro Edition
December 2003
Vue de la page 0
1 2 3 4 5 6 ... 77 78

Résumé du contenu

Page 1 - Basic Customization Guide

Sun Microsystems, Inc.4159 Network CircleSanta Clara, CA 95054U.S.A. 650-960-1300Basic Customization GuideWireless Toolkit, Version 2.1JavaTM2 Platfor

Page 2

x Wireless Toolkit Basic Customization Guide • December 2003

Page 3 - Contents

xiPrefaceThe Java™2 Platform, Micro Edition, Wireless Toolkit Basic Customization Guidedescribes how to customize the J2ME™Wireless Toolkit by modifyi

Page 4

xii Wireless Toolkit Basic Customization Guide • December 2003screen properties, button properties, soft button label areas, and icon properties.The t

Page 5 - Contents v

Preface xiiiTypographic ConventionsShell PromptsRelated DocumentationTypeface Meaning ExamplesAaBbCc123 The names of commands, files,and directories;

Page 6

xiv Wireless Toolkit Basic Customization Guide • December 2003Accessing Sun Documentation OnlineThe Java Developer ConnectionSMweb site enables you to

Page 7

1CHAPTER1Customizing the Wireless ToolkitThe JavaTM2 Platform, Micro Edition Wireless Toolkit (J2METMWireless Toolkit)provides an emulation environmen

Page 8

2 Wireless Toolkit Basic Customization Guide • December 2003Customization StepsYou customize the J2ME Wireless Toolkit for a new device in three simpl

Page 9

Chapter 1 Customizing the Wireless Toolkit 3For example, suppose the J2ME Wireless Toolkit is installed in the directoryC:\WTK21. Then, the Main Devic

Page 10

4 Wireless Toolkit Basic Customization Guide • December 2003

Page 11 - How This Book Is Organized

5CHAPTER2Creating Device Property FilesThis chapter presents a simple tutorial that walks you through the procedures forcreating a device property fil

Page 12

PleaseCopyright © 2003 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, California 95054, U.S.A. All rights reserved.Sun Microsystems, Inc. h

Page 13 - Related Documentation

6 Wireless Toolkit Basic Customization Guide • December 2003Note – All directory names in this chapter refer to the installation directory of theJ2ME

Page 14 - Sun Welcomes Your Comments

Chapter 2 Creating Device Property Files 7pressed_buttons_image = ph1_press.pnghighlighted_image = ph1_highlight.png4. Change the indicator image loca

Page 15

8 Wireless Toolkit Basic Customization Guide • December 2003Total Screen SizeReferring to the left image in FIGURE 1, you specify the total screen siz

Page 16 - Emulator

Chapter 2 Creating Device Property Files 9FIGURE 1 Specifying Screen PropertiesDisplay Area in Full Screen ModeThe MIDP 2.0 specification allows appli

Page 17

10 Wireless Toolkit Basic Customization Guide • December 2003 Bottom right coordinate - the bottom right coordinate of the screen area:(screen.x+scre

Page 18

Chapter 2 Creating Device Property Files 11FIGURE 2 Specifying a Button Location2. Enter the following measured values for the button properties inNew

Page 19 - Property File

12 Wireless Toolkit Basic Customization Guide • December 2003button.7 = 21, 384, 41, 22button.8 = 65, 384, 41, 22button.9 = 111, 384, 41, 22button.POU

Page 20 - Obtain and Enter Image Files

Chapter 2 Creating Device Property Files 13FIGURE 3 Soft Button Label Areas on the Emulated Device DisplayA soft button label display is defined by a

Page 21 - ■ Display Area

14 Wireless Toolkit Basic Customization Guide • December 2003softbutton.0=1,112,40,16, softButton, leftsoftbutton.1=56,112,40,16, softButton, rightObt

Page 22 - Display Area

Chapter 2 Creating Device Property Files 15icon.<name> = <x_location>,<y_location>,<initial_state>The icon states are defined

Page 23

Contents iiiContentsPreface xi1. Customizing the Wireless Toolkit 1How to Customize the Wireless Toolkit 1Customization Steps 2Device Property Files a

Page 24

16 Wireless Toolkit Basic Customization Guide • December 2003Enter Color PropertiesTwo properties are provided to control the color in the Emulator:

Page 25 - NewPhone.properties:

17CHAPTER3Examining Device Property FilesThis chapter explains in detail the structure and content of device property files foran emulated device.The

Page 26

18 Wireless Toolkit Basic Customization Guide • December 2003Device Property FilesThe device property files consist of a set of files that define the

Page 27

Chapter 3 Examining Device Property Files 19Main Device Property FileThis section describes the device property file that the Default Emulator uses to

Page 28

20 Wireless Toolkit Basic Customization Guide • December 2003The font definition is according to the format for describing a system font (see“System F

Page 29

Chapter 3 Examining Device Property Files 21Examplefont.softButton = bitmap_font.propertiesfont.system.bold.medium = bold_font.propertiesA font proper

Page 30 - Enter Color Properties

22 Wireless Toolkit Basic Customization Guide • December 2003..ascii_x-254 = 1149ascii_x-255 = 1154ascii_x-256 = 1160Note – This type of font supports

Page 31

Chapter 3 Examining Device Property Files 23 An image with all the active buttons pressed—to show a button being pressedwhen the user selects it An

Page 32 - Device Property Files

24 Wireless Toolkit Basic Customization Guide • December 2003Screen PropertiesIn this section you specify the properties of the image of the device sc

Page 33 - Main Device Property File

Chapter 3 Examining Device Property Files 25FIGURE 5 Specifying Screen PropertiesScreen LocationReferring to the left image in FIGURE 5, you specify t

Page 34 - Bitmap Fonts

iv Wireless Toolkit Basic Customization Guide • December 20033. Examining Device Property Files 17Device Property Files 18Main Device Property File 19

Page 35

26 Wireless Toolkit Basic Customization Guide • December 2003screen.x = <horizontal distance in pixels>screen.y = <vertical distance in pixel

Page 36 - The Device Image

Chapter 3 Examining Device Property Files 27Referring to the right image in FIGURE 5, the full screen display area is defined asthe upper left coordin

Page 37 - Image with Buttons Pressed

28 Wireless Toolkit Basic Customization Guide • December 2003Screen Border ColorYou have the option of setting the color of the icon area, the softbut

Page 38 - Screen Properties

Chapter 3 Examining Device Property Files 29Device ButtonsThis section describes how to define a button on an emulated device and alsodescribes the as

Page 39 - Screen Location

30 Wireless Toolkit Basic Customization Guide • December 2003 x: The x-coordinate of the left edge of the button image, in pixels relative to theleft

Page 40

Chapter 3 Examining Device Property Files 31FIGURE 6 Specifying a Button LocationAssigning a PC Keyboard Key to a ButtonYou can assign a key on the PC

Page 41 - Screen Background Color

32 Wireless Toolkit Basic Customization Guide • December 2003Note – Virtual key codes are defined by the Abstract Window Toolkit in Java 2Standard Edi

Page 42 - Screen Buffering

Chapter 3 Examining Device Property Files 33There are two ways you can do a button press at the same time as pressing Shift orAlt: Map the buttons to

Page 43 - Device Buttons

34 Wireless Toolkit Basic Customization Guide • December 2003The MIDP implementation in the Wireless Toolkit allocates a command issued bythe applicat

Page 44

Chapter 3 Examining Device Property Files 352. Use the definition command.keys.<command_type> to assign command types topreferred buttons accord

Page 45 - You use a line of the form:

Contents vAssigning Abstract Commands to Buttons 33Displayed Icons 38Defining the Icon Location and States 38Soft Button Label Display 39Color 40Sound

Page 46

36 Wireless Toolkit Basic Customization Guide • December 2003command.keys.BACK = SOFT1command.keys.EXIT = SOFT1command.keys.CANCEL = SOFT1command.keys

Page 47 - Command Type Description

Chapter 3 Examining Device Property Files 37The Abstract Command MenuWhen there are more abstract commands specified by an application than there areb

Page 48

38 Wireless Toolkit Basic Customization Guide • December 2003Displayed IconsAn icon in the context of the Emulator is any graphic, constant or variabl

Page 49

Chapter 3 Examining Device Property Files 39icon.reception: 0, 0, onicon.reception.on: reception.gificon.battery: 80, 0, fullicon.battery.full: batt_3

Page 50 - Secondary Button Assignments

40 Wireless Toolkit Basic Customization Guide • December 2003softbutton.<number> = <x>,<y>,<width>,<height>,<font>

Page 51 - ■ Scroll/Traverse down menu

Chapter 3 Examining Device Property Files 41alert.<alert_type>.sound = <sound_file>where the possible values of <alert_type> are as

Page 52 - Displayed Icons

42 Wireless Toolkit Basic Customization Guide • December 2003LocalesA locale is a geographic or political region or community that shares the samelang

Page 53 - Soft Button Label Display

Chapter 3 Examining Device Property Files 43microedition.encoding: UTF-8microedition.encoding.supported: UTF-8, UTF-16, ISO-8859-1,ISO-8859-2, Shift_J

Page 54 - Sound Alerts

44 Wireless Toolkit Basic Customization Guide • December 2003

Page 55 - Device Software Capabilities

45APPENDIXADefault Emulator DeviceProperty FilesThis appendix presents a list of the device property files provided with the DefaultEmulator and infor

Page 56 - Character Encodings

vi Wireless Toolkit Basic Customization Guide • December 2003

Page 57 - Transparent Images

46 Wireless Toolkit Basic Customization Guide • December 2003DefaultGrayPhone.propertiesdefault_image=..\Share\ph1_neut.pngpressed_buttons_image=..\Sh

Page 58

Appendix A Default Emulator Device Property Files 47screenPixelRatio.x = 1screenPixelRatio.y = 1# Touchscreen support ###############touch_screen=fals

Page 59 - Property Files

48 Wireless Toolkit Basic Customization Guide • December 2003button.SELECT = 97, 370, 50, 28button.DOWN = 97, 398, 50, 22button.CLEAR = 92, 426, 58, 3

Page 60 - DefaultGrayPhone.properties

Appendix A Default Emulator Device Property Files 49# <face> is one of# system, monospace, proportional## <style> is one of# plain, bold,

Page 61

50 Wireless Toolkit Basic Customization Guide • December 2003font.monospace.italic.large: Monospaced-italic-14font.monospace.bold.italic.small: Monosp

Page 62

Appendix A Default Emulator Device Property Files 51icon.down.on: ..\Share\down.gificon.left: 78, 194, officon.left.off:icon.left.on: ..\Share\left.gi

Page 63

52 Wireless Toolkit Basic Customization Guide • December 2003alert.error.sound: ..\Share\mid_err.wavalert.confirmation.sound: ..\Share\mid_confirm.wav

Page 64

Appendix A Default Emulator Device Property Files 53Device Image FilesFIGURE 8 Images of Device Key Press StatesIcon Image FilesThe following table li

Page 65

54 Wireless Toolkit Basic Customization Guide • December 2003internet.gifreception.gifright.gifleft.gifsym.gifkana.gifhira.gifABC.gifabc_lower.gif123.

Page 66

55APPENDIXBSupport for ByteCode ObfuscatorsThe Wireless Toolkit contains a support framework for bytecode obfuscators. It alsoincludes a plug-in for t

Page 67 - Icon Image Files

viiFiguresFIGURE 1 Specifying Screen Properties 9FIGURE 2 Specifying a Button Location 11FIGURE 3 Soft Button Label Areas on the Emulated Device Displ

Page 68

56 Wireless Toolkit Basic Customization Guide • December 2003 run(File jarFileObfuscated, String wtkBinDir,String wtkLibDir, String jarFilename, Stri

Page 69 - Adding a ByteCode Obfuscator

Appendix B Support for ByteCode Obfuscators 57You can get the proguard.jar file by downloading the .zip file fromhttp://proguard.sourceforge.net/ and

Page 70

58 Wireless Toolkit Basic Customization Guide • December 2003

Page 71 - {j2mewtk.dir}\bin

59APPENDIXCConnecting to the Wireless Toolkit’sWMA Emulation EnvironmentThe J2ME Wireless Toolkit supports the Wireless Messaging API (WMA), whichenab

Page 72

60 Wireless Toolkit Basic Customization Guide • December 2003

Page 73 - WMA Emulation Environment

61IndexAabstract command typesassigning to a button, 35abstract commandsassigning to buttons, 33menu operations, 37table of, 33abstract commands, type

Page 74

62 Wireless Toolkit Basic Customization Guide • December 2003font_image property, 21Ggame actions, mapping to buttons, 32generated characters, assigni

Page 75

Index 63device property files, 1WMA messages, customizing, 59

Page 76

64 Wireless Toolkit Basic Customization Guide • December 2003

Page 77 - WMA messages, customizing, 59

viii Wireless Toolkit Basic Customization Guide • December 2003

Page 78

ixTablesTABLE 1 Example of Device Property Files and DefaultGrayPhone Property File 18TABLE 2 Button Names Available 29TABLE 3 Abstract Command Types

Commentaires sur ces manuels

Pas de commentaire