1/************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27 28#include "chinese_dictionarydialog.hrc" 29#include "chinese_translationdialog.hrc" 30 31#include <svtools/controldims.hrc> 32 33#define DIRECTION_RADIOBUTTONS( D_XPOS, D_YPOS, D_FULLWIDTH ) \ 34RadioButton RB_TO_SIMPLIFIED \ 35{ \ 36 Pos = MAP_APPFONT( D_XPOS, D_YPOS ); \ 37 Size = MAP_APPFONT ( D_FULLWIDTH, RSC_CD_RADIOBUTTON_HEIGHT ) ; \ 38 Text [ en-US ] = "~Traditional Chinese to simplified Chinese"; \ 39}; \ 40RadioButton RB_TO_TRADITIONAL \ 41{ \ 42 Pos = MAP_APPFONT( D_XPOS, D_YPOS + RSC_CD_RADIOBUTTON_HEIGHT+RSC_SP_CTRL_GROUP_Y ); \ 43 Size = MAP_APPFONT ( D_FULLWIDTH, RSC_CD_RADIOBUTTON_HEIGHT ) ; \ 44 Text [ en-US ] = "~Simplified Chinese to traditional Chinese"; \ 45}; 46 47//----------------------------------------------------------------------------- 48//defines for positions and sizes: 49 50#define FULL_WIDTH (245) 51#define FULL_HEIGHT (165) 52 53#define ROW_1 (RSC_SP_DLG_INNERBORDER_TOP) 54#define ROW_2 (ROW_1+RSC_CD_RADIOBUTTON_HEIGHT+RSC_SP_CTRL_GROUP_Y) 55#define ROW_3 (ROW_2+RSC_CD_RADIOBUTTON_HEIGHT+RSC_SP_CTRL_GROUP_Y) 56#define ROW_4 (ROW_3+RSC_CD_CHECKBOX_HEIGHT+RSC_SP_CTRL_GROUP_Y) 57#define ROW_5 (ROW_4+RSC_CD_FIXEDTEXT_HEIGHT+RSC_SP_CTRL_DESC_Y) 58#define ROW_6 (ROW_5+RSC_CD_TEXTBOX_HEIGHT+RSC_SP_CTRL_DESC_Y) 59 60#define ROW_5a (ROW_5+RSC_CD_PUSHBUTTON_HEIGHT+RSC_SP_CTRL_DESC_Y) 61#define ROW_5b (ROW_5a+RSC_CD_PUSHBUTTON_HEIGHT+RSC_SP_CTRL_DESC_Y) 62 63#define ROW_8 (FULL_HEIGHT-RSC_SP_DLG_INNERBORDER_BOTTOM-RSC_CD_PUSHBUTTON_HEIGHT) 64#define ROW_7 (ROW_8-RSC_CD_FIXEDLINE_HEIGHT-2) 65 66#define LIST_HEIGHT (ROW_7-RSC_SP_CTRL_Y-ROW_6) 67 68#define COL_WIDTH 60 69#define BUTTONCOL_WIDTH 40 70#define COL_1 (RSC_SP_DLG_INNERBORDER_LEFT+RSC_SP_FLGR_SPACE_X) 71#define COL_2 (COL_1+COL_WIDTH+1) 72#define COL_3 (COL_2+COL_WIDTH+1) 73#define COL_4 (FULL_WIDTH-RSC_SP_DLG_INNERBORDER_RIGHT-BUTTONCOL_WIDTH) 74 75#define REST_COL_WIDTH (COL_4-COL_3-RSC_SP_CTRL_GROUP_X) 76 77//----------------------------------------------------------------------------- 78 79ModalDialog DLG_CHINESEDICTIONARY 80{ 81 HelpID = "svx:ModalDialog:DLG_CHINESEDICTIONARY"; 82 //HelpId = ; 83 Size = MAP_APPFONT( FULL_WIDTH, FULL_HEIGHT ); 84 OutputSize = TRUE; 85 Closeable = TRUE ; 86 Moveable = TRUE ; 87 SVLook = TRUE; 88 89 Text [ en-US ] = "Edit Dictionary"; 90 91 DIRECTION_RADIOBUTTONS( COL_1, ROW_1, FULL_WIDTH - COL_1 - RSC_SP_DLG_INNERBORDER_RIGHT ) 92 93 CheckBox CB_REVERSE 94 { 95 HelpID = "svx:CheckBox:DLG_CHINESEDICTIONARY:CB_REVERSE"; 96 Pos = MAP_APPFONT ( COL_1, ROW_3 ) ; 97 Size = MAP_APPFONT ( FULL_WIDTH - COL_1 - RSC_SP_DLG_INNERBORDER_RIGHT , RSC_CD_CHECKBOX_HEIGHT ) ; 98 99 Text [ en-US ] = "Reverse mapping"; 100 }; 101 102 FixedText FT_TERM 103 { 104 Pos = MAP_APPFONT ( COL_1 , ROW_4 ) ; 105 Size = MAP_APPFONT ( COL_WIDTH, RSC_CD_FIXEDTEXT_HEIGHT ) ; 106 Text [ en-US ] = "Term"; 107 }; 108 Edit ED_TERM 109 { 110 HelpID = "svx:Edit:DLG_CHINESEDICTIONARY:ED_TERM"; 111 Border = TRUE ; 112 Pos = MAP_APPFONT ( COL_1 , ROW_5 ) ; 113 Size = MAP_APPFONT ( COL_WIDTH , RSC_CD_TEXTBOX_HEIGHT ) ; 114 }; 115 116 117 FixedText FT_MAPPING 118 { 119 Pos = MAP_APPFONT ( COL_2 , ROW_4 ) ; 120 Size = MAP_APPFONT ( COL_WIDTH, RSC_CD_FIXEDTEXT_HEIGHT ) ; 121 Text [ en-US ] = "Mapping"; 122 }; 123 Edit ED_MAPPING 124 { 125 HelpID = "svx:Edit:DLG_CHINESEDICTIONARY:ED_MAPPING"; 126 Border = TRUE ; 127 Pos = MAP_APPFONT ( COL_2 , ROW_5 ) ; 128 Size = MAP_APPFONT ( COL_WIDTH , RSC_CD_TEXTBOX_HEIGHT ) ; 129 }; 130 131 FixedText FT_PROPERTY 132 { 133 Pos = MAP_APPFONT ( COL_3 , ROW_4 ) ; 134 Size = MAP_APPFONT ( REST_COL_WIDTH, RSC_CD_FIXEDTEXT_HEIGHT ) ; 135 Text [ en-US ] = "Property"; 136 }; 137 ListBox LB_PROPERTY 138 { 139 HelpID = "svx:ListBox:DLG_CHINESEDICTIONARY:LB_PROPERTY"; 140 Border = TRUE ; 141 Pos = MAP_APPFONT ( COL_3 , ROW_5 ) ; 142 Size = MAP_APPFONT ( REST_COL_WIDTH , RSC_CD_TEXTBOX_HEIGHT ) ; 143 DropDown = TRUE ; 144 145 stringlist [ en-US ] = 146 { 147 < "Other" ; Default ; > ; 148 < "Foreign" ; > ; 149 < "First name" ; > ; 150 < "Last name" ; > ; 151 < "Title" ; > ; 152 < "Status" ; > ; 153 < "Place name" ; > ; 154 < "Business" ; > ; 155 < "Adjective" ; > ; 156 < "Idiom" ; > ; 157 < "Abbreviation" ; > ; 158 < "Numerical" ; > ; 159 < "Noun" ; > ; 160 < "Verb" ; > ; 161 < "Brand name" ; > ; 162 }; 163 }; 164 165 Control CT_MAPPINGLIST 166 { 167 Pos = MAP_APPFONT ( COL_1, ROW_6 ) ; 168 Size = MAP_APPFONT ( COL_4 - COL_1 - RSC_SP_CTRL_GROUP_X, LIST_HEIGHT ) ; 169 TabStop = TRUE ; 170 }; 171 172 PushButton PB_ADD 173 { 174 HelpID = "svx:PushButton:DLG_CHINESEDICTIONARY:PB_ADD"; 175 Pos = MAP_APPFONT( COL_4, ROW_5 ); 176 Size = MAP_APPFONT( BUTTONCOL_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ); 177 178 Text [ en-US ] = "~Add"; 179 }; 180 PushButton PB_MODIFY 181 { 182 HelpID = "svx:PushButton:DLG_CHINESEDICTIONARY:PB_MODIFY"; 183 Pos = MAP_APPFONT( COL_4, ROW_5a ); 184 Size = MAP_APPFONT( BUTTONCOL_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ); 185 186 Text [ en-US ] = "~Modify"; 187 }; 188 PushButton PB_DELETE 189 { 190 HelpID = "svx:PushButton:DLG_CHINESEDICTIONARY:PB_DELETE"; 191 Pos = MAP_APPFONT( COL_4, ROW_5b ); 192 Size = MAP_APPFONT( BUTTONCOL_WIDTH , RSC_CD_PUSHBUTTON_HEIGHT ); 193 194 Text [ en-US ] = "~Delete"; 195 }; 196 197 FixedLine FL_BOTTOMLINE 198 { 199 Pos = MAP_APPFONT ( 0 , ROW_7 ) ; 200 Size = MAP_APPFONT ( FULL_WIDTH, RSC_CD_FIXEDLINE_HEIGHT ) ; 201 }; 202 203 BUTTONS_OK_CANCEL_HELP_ABREAST( FULL_WIDTH - RSC_SP_DLG_INNERBORDER_RIGHT, ROW_8 ) 204}; 205 206//----------------------------------------------------------------------------- 207//defines for positions and sizes: 208 209#define T_FULL_WIDTH (220) 210#define T_FULL_HEIGHT (120) 211#define T_EDITBUTTON_WIDTH (75) 212 213#define T_COL_1 (RSC_SP_DLG_INNERBORDER_LEFT) 214#define T_COL_2 (T_COL_1+RSC_SP_FLGR_SPACE_X) 215#define T_COL_3 (T_COL_2+RSC_SP_CHK_TEXTINDENT) 216#define T_COL_4 (T_FULL_WIDTH-RSC_SP_DLG_INNERBORDER_RIGHT-T_EDITBUTTON_WIDTH) 217 218#define T_ROW_1 (RSC_SP_DLG_INNERBORDER_TOP) 219#define T_ROW_2 (T_ROW_1+RSC_CD_FIXEDLINE_HEIGHT+RSC_SP_CTRL_GROUP_Y) 220#define T_ROW_3 (T_ROW_2+RSC_CD_RADIOBUTTON_HEIGHT+RSC_SP_CTRL_GROUP_Y) 221#define T_ROW_4 (T_ROW_3+RSC_CD_RADIOBUTTON_HEIGHT+RSC_SP_CTRL_DESC_Y) 222#define T_ROW_5 (T_ROW_4+RSC_CD_CHECKBOX_HEIGHT+RSC_SP_CTRL_Y) 223#define T_ROW_6 (T_ROW_5+RSC_CD_FIXEDLINE_HEIGHT+RSC_SP_CTRL_GROUP_Y) 224 225#define T_ROW_8 (T_FULL_HEIGHT-RSC_SP_DLG_INNERBORDER_BOTTOM-RSC_CD_PUSHBUTTON_HEIGHT) 226#define T_ROW_7 (T_ROW_8-RSC_CD_FIXEDLINE_HEIGHT-2) 227 228//----------------------------------------------------------------------------- 229 230ModalDialog DLG_CHINESETRANSLATION 231{ 232 HelpID = "svx:ModalDialog:DLG_CHINESETRANSLATION"; 233 //HelpId = ; 234 Size = MAP_APPFONT( T_FULL_WIDTH, T_FULL_HEIGHT ); 235 OutputSize = TRUE; 236 Closeable = TRUE ; 237 Moveable = TRUE ; 238 SVLook = TRUE; 239 240 Text [ en-US ] = "Chinese Conversion"; 241 242 FixedLine FL_DIRECTION 243 { 244 Pos = MAP_APPFONT ( T_COL_1 , T_ROW_1 ) ; 245 Size = MAP_APPFONT ( T_FULL_WIDTH - T_COL_1 - RSC_SP_DLG_INNERBORDER_RIGHT, RSC_CD_FIXEDLINE_HEIGHT ) ; 246 Text [ en-US ] = "Conversion direction"; 247 }; 248 249 DIRECTION_RADIOBUTTONS( T_COL_2, T_ROW_2, (T_FULL_WIDTH - T_COL_2 - RSC_SP_DLG_INNERBORDER_RIGHT) ) 250 251 CheckBox CB_USE_VARIANTS 252 { 253 HelpID = "svx:CheckBox:DLG_CHINESETRANSLATION:CB_USE_VARIANTS"; 254 Pos = MAP_APPFONT( T_COL_3, T_ROW_4 ); 255 Size = MAP_APPFONT ( T_FULL_WIDTH - T_COL_3 - RSC_SP_DLG_INNERBORDER_RIGHT, RSC_CD_CHECKBOX_HEIGHT ) ; 256 257 Text [ en-US ] = "~Use Taiwan, Hong Kong SAR, and Macao SAR character variants"; 258 }; 259 260 FixedLine FL_COMMONTERMS 261 { 262 Pos = MAP_APPFONT ( T_COL_1 , T_ROW_5 ) ; 263 Size = MAP_APPFONT ( T_FULL_WIDTH - T_COL_1 - RSC_SP_DLG_INNERBORDER_RIGHT, RSC_CD_FIXEDLINE_HEIGHT ) ; 264 Text [ en-US ] = "Common terms"; 265 }; 266 267 CheckBox CB_TRANSLATE_COMMONTERMS 268 { 269 HelpID = "svx:CheckBox:DLG_CHINESETRANSLATION:CB_TRANSLATE_COMMONTERMS"; 270 Pos = MAP_APPFONT( T_COL_2, T_ROW_6 ); 271 Size = MAP_APPFONT ( T_COL_4 - T_COL_2, RSC_CD_CHECKBOX_HEIGHT ) ; 272 273 Text [ en-US ] = "Translate ~common terms"; 274 }; 275 276 PushButton PB_EDITTERMS 277 { 278 HelpID = "svx:PushButton:DLG_CHINESETRANSLATION:PB_EDITTERMS"; 279 Pos = MAP_APPFONT( T_COL_4, T_ROW_6-(RSC_CD_PUSHBUTTON_HEIGHT-RSC_CD_CHECKBOX_HEIGHT)/2 ); 280 Size = MAP_APPFONT( T_EDITBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT ); 281 282 Text [ en-US ] = "~Edit Terms..."; 283 }; 284 285 FixedLine T_FL_BOTTOMLINE 286 { 287 Pos = MAP_APPFONT ( 0 , T_ROW_7 ) ; 288 Size = MAP_APPFONT ( T_FULL_WIDTH, RSC_CD_FIXEDLINE_HEIGHT ) ; 289 }; 290 291 BUTTONS_OK_CANCEL_HELP_ABREAST( T_FULL_WIDTH - RSC_SP_DLG_INNERBORDER_RIGHT, T_ROW_8 ) 292}; 293 294