From 2e3f810f31963dfef4b46dc2f079ebed7453d420 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Delgado?= Date: Tue, 2 Feb 2021 23:31:06 +0100 Subject: [PATCH] Icon changes --- .gitignore | 3 +- src/tm/ui/TMPalettePane.java | 10 ++--- src/tm/ui/TMUI.java | 74 ++++++++++++++++++------------------ 3 files changed, 44 insertions(+), 43 deletions(-) diff --git a/.gitignore b/.gitignore index bb4dca6..bcd794a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ build dist compile.sh -.vscode \ No newline at end of file +.vscode +src/languages \ No newline at end of file diff --git a/src/tm/ui/TMPalettePane.java b/src/tm/ui/TMPalettePane.java index 4e03a07..a886422 100644 --- a/src/tm/ui/TMPalettePane.java +++ b/src/tm/ui/TMPalettePane.java @@ -54,11 +54,11 @@ public class TMPalettePane extends JPanel implements MouseInputListener { private ColorBox bgColorBox = new ColorBox(); ClassLoader cl = getClass().getClassLoader(); - private Cursor pickupCursor = Toolkit.getDefaultToolkit().createCustomCursor(new ImageIcon(cl.getResource("tm/icons/Dropper24.gif")).getImage(), new Point(8,23), "Dropper"); - private JButton decButton = new JButton(new ImageIcon(cl.getResource("tm/icons/DecPalIndex24.gif"))); - private JButton incButton = new JButton(new ImageIcon(cl.getResource("tm/icons/IncPalIndex24.gif"))); - private JButton leftShiftButton = new JButton(new ImageIcon(cl.getResource("tm/icons/DecPalIndex24.gif"))); - private JButton rightShiftButton = new JButton(new ImageIcon(cl.getResource("tm/icons/IncPalIndex24.gif"))); + private Cursor pickupCursor = Toolkit.getDefaultToolkit().createCustomCursor(new ImageIcon(cl.getResource("tm/icons/Dropper24.png")).getImage(), new Point(8,23), "Dropper"); + private JButton decButton = new JButton(new ImageIcon(cl.getResource("tm/icons/DecPalIndex24.png"))); + private JButton incButton = new JButton(new ImageIcon(cl.getResource("tm/icons/IncPalIndex24.png"))); + private JButton leftShiftButton = new JButton(new ImageIcon(cl.getResource("tm/icons/DecPalIndex24.png"))); + private JButton rightShiftButton = new JButton(new ImageIcon(cl.getResource("tm/icons/IncPalIndex24.png"))); private JButton swapButton = new JButton(new ImageIcon(cl.getResource("tm/icons/Swap24.gif"))); private JTextField shiftValueField = new JTextField("1"); /** diff --git a/src/tm/ui/TMUI.java b/src/tm/ui/TMUI.java index 98718a4..6827537 100644 --- a/src/tm/ui/TMUI.java +++ b/src/tm/ui/TMUI.java @@ -122,50 +122,50 @@ public class TMUI extends JFrame { // toolbar buttons ClassLoader cl = getClass().getClassLoader(); - private ToolButton newButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/New24.gif"))); - private ToolButton openButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Open24.gif"))); - private ToolButton saveButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Save24.gif"))); - private ToolButton cutButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Cut24.gif"))); - private ToolButton copyButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Copy24.gif"))); - private ToolButton pasteButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Paste24.gif"))); - private ToolButton undoButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Undo24.gif"))); - private ToolButton redoButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Redo24.gif"))); - private ToolButton gotoButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Import24.gif"))); - private ToolButton addBookmarkButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Bookmarks24.gif"))); - private ToolButton decWidthButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/DecWidth24.gif"))); - private ToolButton incWidthButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/IncWidth24.gif"))); - private ToolButton decHeightButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/DecHeight24.gif"))); - private ToolButton incHeightButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/IncHeight24.gif"))); + private ToolButton newButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/New24.png"))); + private ToolButton openButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Open24.png"))); + private ToolButton saveButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Save24.png"))); + private ToolButton cutButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Cut24.png"))); + private ToolButton copyButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Copy24.png"))); + private ToolButton pasteButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Paste24.png"))); + private ToolButton undoButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Undo24.png"))); + private ToolButton redoButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Redo24.png"))); + private ToolButton gotoButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Import24.png"))); + private ToolButton addBookmarkButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Bookmarks24.png"))); + private ToolButton decWidthButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/DecWidth24.png"))); + private ToolButton incWidthButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/IncWidth24.png"))); + private ToolButton decHeightButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/DecHeight24.png"))); + private ToolButton incHeightButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/IncHeight24.png"))); // navigation bar buttons - private ToolButton minusPageButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Rewind24.gif"))); - private ToolButton minusRowButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/StepBack24.gif"))); - private ToolButton minusTileButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Back24.gif"))); - private ToolButton minusByteButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Minus24.gif"))); - private ToolButton plusByteButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Plus24.gif"))); - private ToolButton plusTileButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Forward24.gif"))); - private ToolButton plusRowButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/StepForward24.gif"))); - private ToolButton plusPageButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/FastForward24.gif"))); + private ToolButton minusPageButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Rewind24.png"))); + private ToolButton minusRowButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/StepBack24.png"))); + private ToolButton minusTileButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Back24.png"))); + private ToolButton minusByteButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Minus24.png"))); + private ToolButton plusByteButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Plus24.png"))); + private ToolButton plusTileButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Forward24.png"))); + private ToolButton plusRowButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/StepForward24.png"))); + private ToolButton plusPageButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/FastForward24.png"))); // tool palette buttons - private ToolToggleButton selectButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Selection24.gif"))); - private ToolToggleButton zoomButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Zoom24.gif"))); - private ToolToggleButton pickupButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Dropper24.gif"))); - private ToolToggleButton brushButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Brush24.gif"))); - private ToolToggleButton lineButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Line24.gif"))); - private ToolToggleButton fillButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Fill24.gif"))); - private ToolToggleButton replaceButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/ColorReplacer24.gif"))); + private ToolToggleButton selectButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Selection24.png"))); + private ToolToggleButton zoomButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Zoom24.png"))); + private ToolToggleButton pickupButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Dropper24.png"))); + private ToolToggleButton brushButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Brush24.png"))); + private ToolToggleButton lineButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Line24.png"))); + private ToolToggleButton fillButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Fill24.png"))); + private ToolToggleButton replaceButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/ColorReplacer24.png"))); private ToolToggleButton moveButton = new ToolToggleButton(new ImageIcon(cl.getResource("tm/icons/Mover24.gif"))); // selection palette buttons - private ToolButton mirrorButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Mirror24.gif"))); - private ToolButton flipButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Flip24.gif"))); - private ToolButton rotateRightButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/RotateRight24.gif"))); - private ToolButton rotateLeftButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/RotateLeft24.gif"))); - private ToolButton shiftLeftButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/ShiftLeft24.gif"))); - private ToolButton shiftRightButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/ShiftRight24.gif"))); - private ToolButton shiftUpButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/ShiftUp24.gif"))); - private ToolButton shiftDownButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/ShiftDown24.gif"))); + private ToolButton mirrorButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Mirror24.png"))); + private ToolButton flipButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/Flip24.png"))); + private ToolButton rotateRightButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/RotateRight24.png"))); + private ToolButton rotateLeftButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/RotateLeft24.png"))); + private ToolButton shiftLeftButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/ShiftLeft24.png"))); + private ToolButton shiftRightButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/ShiftRight24.png"))); + private ToolButton shiftUpButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/ShiftUp24.png"))); + private ToolButton shiftDownButton = new ToolButton(new ImageIcon(cl.getResource("tm/icons/ShiftDown24.png"))); // File menu private JMenu fileMenu = new JMenu("File");