1 <?xml version=
"1.0" encoding=
"ISO-8859-1"?> 
   3 <resource xmlns=
"http://www.wxwidgets.org/wxxrc" version=
"2.3.0.1"> 
   5 <object class=
"wxDialog" name=
"platform_property_dialog"> 
   6     <title>Platform Property Example
</title> 
   8     <object class=
"wxFlexGridSizer"> 
  13         <growablecols>0</growablecols> 
  14         <growablerows>0</growablerows> 
  15         <object class=
"sizeritem"> 
  16             <flag>wxGROW|wxALIGN_CENTER_VERTICAL|wxALL
</flag> 
  18             <object class=
"wxTextCtrl" name=
"message_textctrl"> 
  20                 <style>wxTE_MULTILINE
</style> 
  21                 <value>You can specify certain nodes of an XRC file to only be used for a certain platform.\n\nTo do this, there is a "platform" property that can be placed in any node [ie inside an opening tag]. The value of the tag can be any combination of the following: mac, win, unix, or os2. Use a | symbol between multiple platforms, for example 
<label 
platform="win|mac"
>\n\nAt runtime, if there is a platform property in the tag, if it matches the current operating system, that node will be included, otherwise it won't.\n\nThe notebook example below shows how you can specify a high level node to only appear on a certain platform: the example here being a page of  preferences that only make sense on a certain platform.\n\nThe second example shows how to replace a single attribute of a control: here the label of a download link. It is also very useful for specifying menu item accelerators keystrokes on the target platform.
</value> 
  24         <object class=
"sizeritem"> 
  25             <flag>wxGROW|wxALIGN_CENTER_VERTICAL|wxALL
</flag> 
  27             <object class=
"wxNotebook" name=
"platform_notebook"> 
  29                 <object class=
"notebookpage"> 
  30                     <label>Shared options
</label> 
  31                     <object class=
"wxPanel" name=
"shared_tab"> 
  32                         <object class=
"wxBoxSizer"> 
  33                             <orient>wxVERTICAL
</orient> 
  34                             <object class=
"sizeritem"> 
  35                                 <flag>wxALIGN_CENTRE|wxALL
</flag> 
  37                                 <object class=
"wxCheckBox" name=
"shared_checkbox"> 
  38                                     <label>This preference is for all operating systems
</label> 
  44                 <object platform=
"mac" class=
"notebookpage"> 
  45                     <label>Macintosh options
</label> 
  46                     <object class=
"wxPanel" name=
"mac_specific"> 
  47                         <object class=
"wxBoxSizer"> 
  48                             <orient>wxVERTICAL
</orient> 
  49                             <object class=
"sizeritem"> 
  50                                 <flag>wxALIGN_CENTRE|wxALL
</flag> 
  52                                 <object class=
"wxCheckBox" name=
"mac_checkbox"> 
  53                                     <label>Save output in iMovie compatible format
</label> 
  59                 <object platform=
"win" class=
"notebookpage"> 
  60                     <label>Windows options
</label> 
  61                     <object class=
"wxPanel" name=
"win_specific"> 
  62                         <object class=
"wxBoxSizer"> 
  63                             <orient>wxVERTICAL
</orient> 
  64                             <object class=
"sizeritem"> 
  65                                 <flag>wxALIGN_CENTRE|wxALL
</flag> 
  67                                 <object class=
"wxCheckBox" name=
"win_checkbox"> 
  68                                     <label>Show application in icon tray instead of taskbar
</label> 
  74                 <object platform=
"unix" class=
"notebookpage"> 
  75                     <label>Linux options
</label> 
  76                     <object class=
"wxPanel" name=
"unix_specific"> 
  77                         <object class=
"wxBoxSizer"> 
  78                             <orient>wxVERTICAL
</orient> 
  79                             <object class=
"sizeritem"> 
  80                                 <flag>wxALIGN_CENTRE|wxALL
</flag> 
  82                                 <object class=
"wxCheckBox" name=
"unix_checkbox"> 
  83                                     <label>Check my home directory for previous files
</label> 
  89                 <object platform=
"os2" class=
"notebookpage"> 
  90                     <label>OS2 options
</label> 
  91                     <object class=
"wxPanel" name=
"os2_specific"> 
  92                         <object class=
"wxBoxSizer"> 
  93                             <orient>wxVERTICAL
</orient> 
  94                             <object class=
"sizeritem"> 
  95                                 <flag>wxALIGN_CENTRE|wxALL
</flag> 
  97                                 <object class=
"wxCheckBox" name=
"os2_checkbox"> 
  98                                     <label>Use WarpIn installer
</label> 
 106         <object platform=
"mac" class=
"sizeritem"> 
 107             <flag>wxALIGN_CENTRE|wxALL
</flag> 
 109             <object class=
"wxStaticText" name=
"download_mac_statictext"> 
 110                 <label>Get latest update at www.mycompany.com/download/mac
</label> 
 113         <object platform=
"win" class=
"sizeritem">  
 114             <flag>wxALIGN_CENTRE|wxALL
</flag> 
 116             <object class=
"wxStaticText" name=
"download_win_statictext"> 
 117                 <label>Get latest update at www.mycompany.com/download/win
</label> 
 120         <object platform=
"unix" class=
"sizeritem"> 
 121             <flag>wxALIGN_CENTRE|wxALL
</flag> 
 123             <object class=
"wxStaticText" name=
"download_unix_statictext"> 
 124                 <label>Get latest update at www.mycompany.com/download/unix
</label> 
 127         <object platform=
"os2" class=
"sizeritem"> 
 128             <flag>wxALIGN_CENTRE|wxALL
</flag> 
 130             <object class=
"wxStaticText" name=
"download_os2_statictext"> 
 131                 <label>Get latest update at www.mycompany.com/download/os2
</label> 
 134         <object class=
"sizeritem"> 
 135             <flag>wxALIGN_CENTRE|wxALL
</flag> 
 137             <object class=
"wxButton" name=
"wxID_OK">