diff --git a/TileMolester.jar b/TileMolester.jar
index 998932b..a2a72b7 100644
Binary files a/TileMolester.jar and b/TileMolester.jar differ
diff --git a/resources/TM200.xml b/resources/TM200.xml
new file mode 100644
index 0000000..556c2c3
--- /dev/null
+++ b/resources/TM200.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/settings.xml b/settings.xml
index 8141421..a60a15f 100644
--- a/settings.xml
+++ b/settings.xml
@@ -5,6 +5,7 @@
+
diff --git a/src/TileMolester.java b/src/TileMolester.java
index 28a438a..b3594c0 100644
--- a/src/TileMolester.java
+++ b/src/TileMolester.java
@@ -16,8 +16,12 @@
*
*/
+import javax.swing.UIManager;
+
import tm.ui.TMUI;
+
+
/**
*
* Tile Molester main class.
@@ -35,8 +39,18 @@ public class TileMolester {
*
**/
+ private static String OS = System.getProperty("os.name").toLowerCase();
+ public static Boolean isLinux = OS.indexOf("nix") >= 0 || OS.indexOf("nux") >= 0 || OS.indexOf("aix") > 0;
+ public static Boolean isWindows = OS.indexOf("win") >= 0;
+
public TileMolester() {
- new TMUI();
+ try {
+ if(isLinux) UIManager.setLookAndFeel("com.sun.java.swing.plaf.gtk.GTKLookAndFeel");
+ if(isWindows) UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ new TMUI();
}
/**
diff --git a/src/tm/ui/TMStatusBar.java b/src/tm/ui/TMStatusBar.java
index e88ba2c..ac8cd94 100644
--- a/src/tm/ui/TMStatusBar.java
+++ b/src/tm/ui/TMStatusBar.java
@@ -72,12 +72,12 @@ public class TMStatusBar extends JPanel {
add(p3);
// pane.add(new JLabel(" ")); // just some whitespace
- offsetLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
- coordsLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
- palOffsetLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
- codecLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
- modeLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
- tilesLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
+ //offsetLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
+ //coordsLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
+ //palOffsetLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
+ //codecLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
+ //modeLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
+ //tilesLabel.setBorder(new BevelBorder(BevelBorder.LOWERED));
}
/**
diff --git a/src/tm/ui/TMUI.java b/src/tm/ui/TMUI.java
index e8e8944..5922585 100644
--- a/src/tm/ui/TMUI.java
+++ b/src/tm/ui/TMUI.java
@@ -258,7 +258,7 @@ public class TMUI extends JFrame {
// Help menu
private JMenu helpMenu = new JMenu("Help");
private JMenuItem helpTopicsMenuItem = new JMenuItem("Help Topics");
- private JMenuItem tipMenuItem = new JMenuItem("Tip of the Millennium...");
+ //private JMenuItem tipMenuItem = new JMenuItem("Tip of the Millennium..."); // Still say no to drugs, okay?
private JMenuItem aboutMenuItem = new JMenuItem("About Tile Molester...");
// button groups
@@ -370,7 +370,7 @@ public class TMUI extends JFrame {
JComponent.setDefaultLocale(this.locale);
// show splash screen
- new TMSplashScreen(this);
+ //new TMSplashScreen(this); // No need for a splash screen, it runs immediately on modern systems
// create a translator
try {
@@ -474,7 +474,6 @@ public class TMUI extends JFrame {
// Help menu
helpMenu.setText(xlate("Help"));
helpTopicsMenuItem.setText(xlate("Help_Topics"));
- tipMenuItem.setText(xlate("Tip_of_the_Millennium"));
aboutMenuItem.setText(xlate("About_Tile_Molester"));
UIManager.put("OptionPane.yesButtonText", xlate("Yes"));
@@ -561,7 +560,8 @@ public class TMUI extends JFrame {
// main toolbar
initToolBar();
initNavBar();
- toolBarPane.setLayout(new FlowLayout(FlowLayout.LEFT));
+ toolBarPane.setLayout(new FlowLayout(FlowLayout.LEFT));
+ toolBarPane.setBackground(MenuBG);
toolBarPane.add(toolBar);
toolBarPane.add(navBar);
pane.add(toolBarPane, BorderLayout.NORTH);
@@ -571,7 +571,7 @@ public class TMUI extends JFrame {
// palette pane & statusbar
palettePane = new TMPalettePane(this);
- statusBar.setBorder(new BevelBorder(BevelBorder.LOWERED));
+ //statusBar.setBorder(new BevelBorder(BevelBorder.LOWERED));
bottomPane.setLayout(new BorderLayout());
bottomPane.add(palettePane, BorderLayout.CENTER);
bottomPane.add(statusBar, BorderLayout.SOUTH);
@@ -583,7 +583,8 @@ public class TMUI extends JFrame {
JPanel barPane = new JPanel();
barPane.setLayout(new GridLayout(1, 2));
barPane.add(selectionToolBar);
- barPane.add(toolPalette);
+ barPane.add(toolPalette);
+ toolPane.setBackground(AsideBG);
toolPane.setLayout(new BorderLayout());
toolPane.add(barPane, BorderLayout.NORTH);
pane.add(toolPane, BorderLayout.WEST);
@@ -628,6 +629,7 @@ public class TMUI extends JFrame {
doExitCommand();
}
public void windowActivated(WindowEvent e) {
+ setExtendedState(JFrame.NORMAL); // Hacky way to make it not run in full screen by default
// HACK to fix the GUI after running FCEU in fullscreen mode
// int state = getExtendedState();
// setExtendedState(JFrame.ICONIFIED);
@@ -1159,7 +1161,7 @@ public class TMUI extends JFrame {
toolButtonGroup.add(replaceButton);
toolButtonGroup.add(moveButton);
selectButton.setSelected(true); // starting tool
- toolPalette.setBorder(new BevelBorder(BevelBorder.LOWERED));
+ //toolPalette.setBorder(new BevelBorder(BevelBorder.LOWERED));
}
/**
@@ -1318,7 +1320,7 @@ public class TMUI extends JFrame {
);
fileMenu.add(closeAllMenuItem);
//
- fileMenu.addSeparator();
+ //fileMenu.addSeparator();
// Save
saveMenuItem.setMnemonic(KeyEvent.VK_S);
saveMenuItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_S, Event.CTRL_MASK));
@@ -2009,16 +2011,7 @@ public class TMUI extends JFrame {
}
);
helpMenu.add(helpTopicsMenuItem);
- // Tip of the Millennium
- tipMenuItem.setMnemonic(KeyEvent.VK_M);
- tipMenuItem.addActionListener(
- new ActionListener() {
- public void actionPerformed(ActionEvent e) {
- doTipCommand();
- }
- }
- );
- helpMenu.add(tipMenuItem);
+
// About
aboutMenuItem.setMnemonic(KeyEvent.VK_A);
aboutMenuItem.addActionListener(
@@ -2130,8 +2123,8 @@ public class TMUI extends JFrame {
// remove view from the FileImage and desktop
img.removeView(view);
- view.dispose();
desktop.remove(view);
+ view.dispose();
desktop.revalidate();
desktop.repaint();
@@ -2239,8 +2232,8 @@ public class TMUI extends JFrame {
// remove the view
img.removeView(view);
- view.dispose();
desktop.remove(view);
+ view.dispose();
}
buildReopenMenu();
@@ -2719,7 +2712,7 @@ public class TMUI extends JFrame {
public void doAboutCommand()
{
JOptionPane.showMessageDialog(this,
- "Tile Molester v0.19\nby SnowBro 2003-2005 (v0.16)\nby Dr. MefistO 2013 (v0.17.2)\nby Mewster 2014-2015 (v0.19)", "Tile Molester",
+ "Tile Molester v0.20\nby SnowBro 2003-2005 (v0.16)\nby Dr. MefistO 2013 (v0.17.2)\nby Mewster 2014-2015 (v0.19)\nby toruzz 2020 (v0.20)", "Tile Molester",
1);
}
diff --git a/src/tm/ui/TMView.java b/src/tm/ui/TMView.java
index e66a3dd..a3d3e1f 100644
--- a/src/tm/ui/TMView.java
+++ b/src/tm/ui/TMView.java
@@ -43,6 +43,9 @@ import java.util.Vector;
**/
public class TMView extends JInternalFrame implements ChangeListener {
+ Color MenuBG = TMUI.MenuBG;
+ Color WindowBG = TMUI.WindowBG;
+ Color AsideBG = TMUI.AsideBG;
private static int frameCount = 0;
private JPanel contentPane = new JPanel();
@@ -77,7 +80,10 @@ public class TMView extends JInternalFrame implements ChangeListener {
this.fileImage = fileImage;
fileImage.addView(this);
setDoubleBuffered(true);
- setBackground(Color.gray);
+ //setBackground(Color.gray);
+ setFrameIcon(null);
+ setBackground(MenuBG);
+
setDefaultCloseOperation(JInternalFrame.DO_NOTHING_ON_CLOSE);
addInternalFrameListener(new InternalFrameAdapter() {
@@ -99,7 +105,8 @@ public class TMView extends JInternalFrame implements ChangeListener {
// init UI components
// the panel containing the slider and editor canvas
- contentPane.setBackground(Color.gray);
+ //contentPane.setBackground(Color.gray);
+ contentPane.setBackground(AsideBG);
contentPane.setLayout(null);
contentPane.setFocusable(true);
contentPane.addKeyListener(new ViewKeyListener(this));
@@ -120,9 +127,12 @@ public class TMView extends JInternalFrame implements ChangeListener {
// the slider
slider.setFocusable(false);
slider.setInverted(true);
- contentPane.add(slider);
- slider.setLocation(0, 0);
- slider.setSize(24, 384);
+ contentPane.add(slider);
+ slider.setForeground(AsideBG);
+ //slider.setLocation(0, 0);
+ //slider.setSize(24, 384);
+ slider.setLocation(4, -14);
+ slider.setSize(32, 424);
slider.addChangeListener(this);
// the scrollpane