| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -661,7 +661,8 @@ public DefaultMutableTreeNode buildExamplesTree() { | |||
| 661 | 661 | } | |
| 662 | 662 | } | |
| 663 | 663 | ||
| 664 | - DefaultMutableTreeNode foundationLibraries = new DefaultMutableTreeNode("Core Libraries"); | ||
| 664 | + DefaultMutableTreeNode foundationLibraries = | ||
| 665 | + new DefaultMutableTreeNode(Language.text("examples.core_libraries")); | ||
| 665 | 666 | ||
| 666 | 667 | // Get examples for core libraries | |
| 667 | 668 | for (Library lib : coreLibraries) { | |
@@ -676,7 +677,8 @@ public DefaultMutableTreeNode buildExamplesTree() { | |||
| 676 | 677 | } | |
| 677 | 678 | ||
| 678 | 679 | // Get examples for third party libraries | |
| 679 | - DefaultMutableTreeNode contributed = new DefaultMutableTreeNode("Libraries"); | ||
| 680 | + DefaultMutableTreeNode contributed = new | ||
| 681 | + DefaultMutableTreeNode(Language.text("examples.libraries")); | ||
| 680 | 682 | for (Library lib : contribLibraries) { | |
| 681 | 683 | if (lib.hasExamples()) { | |
| 682 | 684 | DefaultMutableTreeNode libNode = new DefaultMutableTreeNode(lib.getName()); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -131,7 +131,7 @@ public void done() { | |||
| 131 | 131 | // to close the progress bar automatically when done, and to | |
| 132 | 132 | // print that adding file is done in Message Area | |
| 133 | 133 | ||
| 134 | - editor.statusNotice("One file added to the sketch."); | ||
| 134 | + editor.statusNotice(Language.text("editor.status.drag_and_drop.files_added.1")); | ||
| 135 | 135 | ProgressFrame.this.closeProgressBar(); | |
| 136 | 136 | } | |
| 137 | 137 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -26,7 +26,7 @@ | |||
| 26 | 26 | import java.util.List; | |
| 27 | 27 | ||
| 28 | 28 | import processing.core.PApplet; | |
| 29 | - | ||
| 29 | + import processing.app.Language; | ||
| 30 | 30 | ||
| 31 | 31 | abstract public class Contribution { | |
| 32 | 32 | static final String SPECIAL_CATEGORY_NAME = "Starred"; | |
@@ -251,6 +251,7 @@ static List<String> parseCategories(String categoryStr) { | |||
| 251 | 251 | String[] listing = PApplet.trim(PApplet.split(categoryStr, ',')); | |
| 252 | 252 | for (String category : listing) { | |
| 253 | 253 | if (validCategories.contains(category)) { | |
| 254 | + category = translateCategory(category); | ||
| 254 | 255 | outgoing.add(category); | |
| 255 | 256 | } | |
| 256 | 257 | } | |
@@ -276,4 +277,55 @@ static List<String> parseImports(String importStr) { | |||
| 276 | 277 | } | |
| 277 | 278 | return (outgoing.size() > 0) ? outgoing : null; | |
| 278 | 279 | } | |
| 280 | + | ||
| 281 | + static private String translateCategory(String cat) { | ||
| 282 | + String translated = ""; | ||
| 283 | + | ||
| 284 | + switch (cat) { | ||
| 285 | + case "3D": | ||
| 286 | + translated = Language.text("contrib.category.3d"); | ||
| 287 | + break; | ||
| 288 | + case "Animation": | ||
| 289 | + translated = Language.text("contrib.category.animation"); | ||
| 290 | + break; | ||
| 291 | + case "Data": | ||
| 292 | + translated = Language.text("contrib.category.data"); | ||
| 293 | + break; | ||
| 294 | + case "Geometry": | ||
| 295 | + translated = Language.text("contrib.category.geometry"); | ||
| 296 | + break; | ||
| 297 | + case "GUI": | ||
| 298 | + translated = Language.text("contrib.category.gui"); | ||
| 299 | + break; | ||
| 300 | + case "Hardware": | ||
| 301 | + translated = Language.text("contrib.category.hardware"); | ||
| 302 | + break; | ||
| 303 | + case "I/O": | ||
| 304 | + translated = Language.text("contrib.category.io"); | ||
| 305 | + break; | ||
| 306 | + case "Math": | ||
| 307 | + translated = Language.text("contrib.category.math"); | ||
| 308 | + break; | ||
| 309 | + case "Simulation": | ||
| 310 | + translated = Language.text("contrib.category.simulation"); | ||
| 311 | + break; | ||
| 312 | + case "Sound": | ||
| 313 | + translated = Language.text("contrib.category.sound"); | ||
| 314 | + break; | ||
| 315 | + case "Typography": | ||
| 316 | + translated = Language.text("contrib.category.typography"); | ||
| 317 | + break; | ||
| 318 | + case "Utilities": | ||
| 319 | + translated = Language.text("contrib.category.utilities"); | ||
| 320 | + break; | ||
| 321 | + case "Video & Vision": | ||
| 322 | + translated = Language.text("contrib.category.video_vision"); | ||
| 323 | + break; | ||
| 324 | + case "Other": | ||
| 325 | + translated = Language.text("contrib.category.other"); | ||
| 326 | + break; | ||
| 327 | + } | ||
| 328 | + return translated; | ||
| 329 | + } | ||
| 330 | + | ||
| 279 | 331 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -125,7 +125,7 @@ public void fileSelected(File newbie) { | |||
| 125 | 125 | e.printStackTrace(); | |
| 126 | 126 | } | |
| 127 | 127 | } else { | |
| 128 | - editor.statusNotice("Archive sketch canceled."); | ||
| 128 | + editor.statusNotice(Language.text("editor.status.archiver.cancel")); | ||
| 129 | 129 | } | |
| 130 | 130 | } | |
| 131 | 131 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -63,7 +63,8 @@ public void run() { | |||
| 63 | 63 | synchronized(ColorSelector.class) { | |
| 64 | 64 | if (selector == null) { | |
| 65 | 65 | selector = new ColorChooser(editor, false, Color.WHITE, | |
| 66 | - "Copy", new ActionListener() { | ||
| 66 | + Language.text("menu.edit.copy"), | ||
| 67 | + new ActionListener() { | ||
| 67 | 68 | ||
| 68 | 69 | @Override | |
| 69 | 70 | public void actionPerformed(ActionEvent e) { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -95,10 +95,7 @@ public void init(Editor editor) { | |||
| 95 | 95 | ||
| 96 | 96 | pain.setLayout(new BoxLayout(pain, BoxLayout.Y_AXIS)); | |
| 97 | 97 | ||
| 98 | - String labelText = | ||
| 99 | - "Use this tool to create bitmap fonts for your program.\n" + | ||
| 100 | - "Select a font and size, and click 'OK' to generate the font.\n" + | ||
| 101 | - "It will be added to the data folder of the current sketch."; | ||
| 98 | + String labelText = Language.text("create_font.label"); | ||
| 102 | 99 | ||
| 103 | 100 | JTextArea textarea = new JTextArea(labelText); | |
| 104 | 101 | textarea.setBorder(new EmptyBorder(10, 10, 20, 10)); | |
@@ -206,7 +203,7 @@ public void valueChanged(ListSelectionEvent e) { | |||
| 206 | 203 | pain.add(new Box.Filler(d2, d2, d2)); | |
| 207 | 204 | ||
| 208 | 205 | JPanel panel = new JPanel(); | |
| 209 | - panel.add(new JLabel("Size:")); | ||
| 206 | + panel.add(new JLabel(Language.text("create_font.size") + ":" )); | ||
| 210 | 207 | sizeSelector = new JTextField(" 48 "); | |
| 211 | 208 | sizeSelector.getDocument().addDocumentListener(new DocumentListener() { | |
| 212 | 209 | public void insertUpdate(DocumentEvent e) { update(); } | |
@@ -215,7 +212,7 @@ public void changedUpdate(DocumentEvent e) { } | |||
| 215 | 212 | }); | |
| 216 | 213 | panel.add(sizeSelector); | |
| 217 | 214 | ||
| 218 | - smoothBox = new JCheckBox("Smooth"); | ||
| 215 | + smoothBox = new JCheckBox(Language.text("create_font.smooth")); | ||
| 219 | 216 | smoothBox.addActionListener(new ActionListener() { | |
| 220 | 217 | public void actionPerformed(ActionEvent e) { | |
| 221 | 218 | smooth = smoothBox.isSelected(); | |
@@ -233,7 +230,7 @@ public void actionPerformed(ActionEvent e) { | |||
| 233 | 230 | // }); | |
| 234 | 231 | // allBox.setSelected(all); | |
| 235 | 232 | // panel.add(allBox); | |
| 236 | - charsetButton = new JButton("Characters..."); | ||
| 233 | + charsetButton = new JButton(Language.text("create_font.characters")); | ||
| 237 | 234 | charsetButton.addActionListener(new ActionListener() { | |
| 238 | 235 | public void actionPerformed(ActionEvent e) { | |
| 239 | 236 | //showCharacterList(); | |
@@ -245,7 +242,7 @@ public void actionPerformed(ActionEvent e) { | |||
| 245 | 242 | pain.add(panel); | |
| 246 | 243 | ||
| 247 | 244 | JPanel filestuff = new JPanel(); | |
| 248 | - filestuff.add(new JLabel("Filename:")); | ||
| 245 | + filestuff.add(new JLabel(Language.text("create_font.filename") + ":")); | ||
| 249 | 246 | filestuff.add(filenameField = new JTextField(20)); | |
| 250 | 247 | filestuff.add(new JLabel(".vlw")); | |
| 251 | 248 | pain.add(filestuff); | |
@@ -503,7 +500,7 @@ class CharacterSelector extends JFrame { | |||
| 503 | 500 | ||
| 504 | 501 | ||
| 505 | 502 | public CharacterSelector() { | |
| 506 | - super("Character Selector"); | ||
| 503 | + super(Language.text("create_font.character_selector")); | ||
| 507 | 504 | ||
| 508 | 505 | charsetList = new CheckBoxList(); | |
| 509 | 506 | DefaultListModel<JCheckBox> model = new DefaultListModel<JCheckBox>(); | |
@@ -526,11 +523,7 @@ public CharacterSelector() { | |||
| 526 | 523 | ||
| 527 | 524 | pain.setLayout(new BoxLayout(pain, BoxLayout.Y_AXIS)); | |
| 528 | 525 | ||
| 529 | - String labelText = | ||
| 530 | - "Default characters will include most bitmaps for Mac OS\n" + | ||
| 531 | - "and Windows Latin scripts. Including all characters may\n" + | ||
| 532 | - "require large amounts of memory for all of the bitmaps.\n" + | ||
| 533 | - "For greater control, you can select specific Unicode blocks."; | ||
| 526 | + String labelText = Language.text("create_font.character_selector.label"); | ||
| 534 | 527 | JTextArea textarea = new JTextArea(labelText); | |
| 535 | 528 | textarea.setBorder(new EmptyBorder(13, 8, 13, 8)); | |
| 536 | 529 | textarea.setBackground(null); | |
@@ -546,9 +539,12 @@ public void actionPerformed(ActionEvent e) { | |||
| 546 | 539 | charsetList.setEnabled(unicodeCharsButton.isSelected()); | |
| 547 | 540 | } | |
| 548 | 541 | }; | |
| 549 | - defaultCharsButton = new JRadioButton("Default Characters"); | ||
| 550 | - allCharsButton = new JRadioButton("All Characters"); | ||
| 551 | - unicodeCharsButton = new JRadioButton("Specific Unicode Blocks"); | ||
| 542 | + defaultCharsButton = | ||
| 543 | + new JRadioButton(Language.text("create_font.default_characters")); | ||
| 544 | + allCharsButton = | ||
| 545 | + new JRadioButton(Language.text("create_font.all_characters")); | ||
| 546 | + unicodeCharsButton = | ||
| 547 | + new JRadioButton(Language.text("create_font.specific_unicode")); | ||
| 552 | 548 | ||
| 553 | 549 | defaultCharsButton.addActionListener(listener); | |
| 554 | 550 | allCharsButton.addActionListener(listener); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -66,6 +66,7 @@ menu.sketch.add_file = Add File... | |||
| 66 | 66 | # | File | Edit | Sketch | Debug | Tools | Help | | |
| 67 | 67 | # | Debug | | |
| 68 | 68 | menu.debug = Debug | |
| 69 | + menu.debug.enable = Enable Debugger | ||
| 69 | 70 | menu.debug.show_debug_toolbar = Show Debug Toolbar | |
| 70 | 71 | menu.debug.debug = Debug | |
| 71 | 72 | menu.debug.continue = Continue | |
@@ -200,6 +201,8 @@ sketchbook.tree = Sketchbook | |||
| 200 | 201 | # Examples (Frame) | |
| 201 | 202 | examples = Examples | |
| 202 | 203 | examples.add_examples = Add Examples... | |
| 204 | + examples.libraries = Libraries | ||
| 205 | + examples.core_libraries = Core Libraries | ||
| 203 | 206 | ||
| 204 | 207 | # Export (Frame) | |
| 205 | 208 | export = Export Options | |
@@ -242,6 +245,16 @@ file = Select an image or other data file to copy to your sketch | |||
| 242 | 245 | ||
| 243 | 246 | # Create Font (Frame) | |
| 244 | 247 | create_font = Create Font | |
| 248 | + create_font.label = Use this tool to create bitmap fonts for your program.\nSelect a font and size, and click 'OK' to generate the font.\n It will be added to the data folder of the current sketch. | ||
| 249 | + create_font.size = Size | ||
| 250 | + create_font.smooth = Smooth | ||
| 251 | + create_font.characters = Characters... | ||
| 252 | + create_font.character_selector = Character Selector | ||
| 253 | + create_font.character_selector.label = Default characters will include most bitmaps for Mac OS\nand Windows Latin scripts. Including all characters may\nrequire large amounts of memory for all of the bitmaps.\nFor greater control, you can select specific Unicode blocks. | ||
| 254 | + create_font.default_characters = Default Characters | ||
| 255 | + create_font.all_characters = All Characters | ||
| 256 | + create_font.specific_unicode = Specific Unicode Blocks | ||
| 257 | + create_font.filename = Filename | ||
| 245 | 258 | ||
| 246 | 259 | # Color Selector (Frame) | |
| 247 | 260 | color_selector = Color Selector | |
@@ -252,6 +265,16 @@ archive_sketch = Archive sketch as... | |||
| 252 | 265 | # Close (Frame) | |
| 253 | 266 | close.unsaved_changes = Save changes to | |
| 254 | 267 | ||
| 268 | + # Tweak Mode | ||
| 269 | + tweak_mode = Tweak Mode | ||
| 270 | + tweak_mode.save_before_tweak = Please save the sketch before running in Tweak Mode. | ||
| 271 | + tweak_mode.keep_changes.line1 = Keep the changes? | ||
| 272 | + tweak_mode.keep_changes.line2 = You changed some values in your sketch. Would you like to keep the changes? | ||
| 273 | + | ||
| 274 | + # DebugTray | ||
| 275 | + debugger.name = Name | ||
| 276 | + debugger.value = Value | ||
| 277 | + debugger.type = Type | ||
| 255 | 278 | ||
| 256 | 279 | # --------------------------------------- | |
| 257 | 280 | # Toolbars | |
@@ -313,8 +336,11 @@ editor.status.printing.done = Done printing. | |||
| 313 | 336 | editor.status.printing.error = Error while printing. | |
| 314 | 337 | editor.status.printing.canceled = Printing canceled. | |
| 315 | 338 | editor.status.copy_as_html = Code formatted as HTML has been copied to the clipboard. | |
| 339 | + editor.status.debug.busy = Debugger busy... | ||
| 316 | 340 | ||
| 317 | 341 | # Errors | |
| 342 | + editor.status.warning = Warning | ||
| 343 | + editor.status.error = Error | ||
| 318 | 344 | editor.status.error_on = Error on | |
| 319 | 345 | editor.status.missing.semi_colon = Missing a semi-colon | |
| 320 | 346 | editor.status.missing.open_sq_bracket = Missing opening square bracket | |
@@ -334,6 +360,9 @@ editor.status.undef_class = The class classname doesn't exist | |||
| 334 | 360 | editor.status.undef_var = The variable varname doesn't exist | |
| 335 | 361 | editor.status.undef_name = The name namefield can't be recognized | |
| 336 | 362 | editor.status.type_mismatch = Type mismatch, typeA doesn't match with typeB | |
| 363 | + editor.status.unused_variable = The value of the local variable varname is not used | ||
| 364 | + editor.status.uninitialized_variable = The local variable varname may not have been initialized | ||
| 365 | + editor.status.no_effect_assignment = The assignment to variable varname has no effect | ||
| 337 | 366 | ||
| 338 | 367 | # Footer buttons | |
| 339 | 368 | editor.footer.errors = Errors | |
@@ -409,6 +438,20 @@ contrib.progress.starting = Starting | |||
| 409 | 438 | contrib.progress.downloading = Downloading | |
| 410 | 439 | contrib.download_error = An error occured while downloading the contribution. | |
| 411 | 440 | contrib.unsupported_operating_system = Your operating system does not appear to be supported. You should visit the %s\'s library for more info. | |
| 441 | + contrib.category.3d = 3D | ||
| 442 | + contrib.category.animation = Animation | ||
| 443 | + contrib.category.data = Data | ||
| 444 | + contrib.category.geometry = Geometry | ||
| 445 | + contrib.category.gui = GUI | ||
| 446 | + contrib.category.hardware = Hardware | ||
| 447 | + contrib.category.io = I/O | ||
| 448 | + contrib.category.math = Math | ||
| 449 | + contrib.category.simulation = Simulation | ||
| 450 | + contrib.category.sound = Sound | ||
| 451 | + contrib.category.typography = Typography | ||
| 452 | + contrib.category.utilities = Utilities | ||
| 453 | + contrib.category.video_vision = Video & Vision | ||
| 454 | + contrib.category.other = Other | ||
| 412 | 455 | ||
| 413 | 456 | # Install on Startup | |
| 414 | 457 | contrib.startup.errors.download_install = Error during download and install of %s | |
| Back | FazBrowse Home | New Git URL |
0 commit comments