Move ribbon icons into own package

This commit is contained in:
skylarmt 2014-12-18 23:57:32 -07:00
parent e365efa3a7
commit 48509cf537
14 changed files with 124 additions and 56 deletions

View File

@ -87,10 +87,9 @@ public class CodeRunner {
this(lang); this(lang);
isShell = shell; isShell = shell;
} }
/** /**
* Inits the Python engine. * Inits the Python engine.
*
* @param fakeInit Set it to true. * @param fakeInit Set it to true.
*/ */
public CodeRunner(boolean fakeInit) { public CodeRunner(boolean fakeInit) {

View File

@ -34,23 +34,25 @@
<Layout> <Layout>
<DimensionLayout dim="0"> <DimensionLayout dim="0">
<Group type="103" groupAlignment="0" attributes="0"> <Group type="103" groupAlignment="0" attributes="0">
<Group type="102" attributes="0"> <Group type="102" alignment="0" attributes="0">
<EmptySpace max="-2" attributes="0"/> <EmptySpace max="-2" attributes="0"/>
<Component id="jPanel1" min="-2" max="-2" attributes="0"/>
<EmptySpace type="unrelated" max="-2" attributes="0"/>
<Group type="103" groupAlignment="0" attributes="0"> <Group type="103" groupAlignment="0" attributes="0">
<Group type="102" alignment="0" attributes="0"> <Group type="102" attributes="0">
<Component id="jPanel1" min="-2" max="-2" attributes="0"/>
<EmptySpace type="unrelated" max="-2" attributes="0"/>
<Component id="jPanel2" min="-2" max="-2" attributes="0"/>
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
</Group>
<Group type="102" alignment="0" attributes="0">
<EmptySpace min="0" pref="0" max="32767" attributes="0"/> <EmptySpace min="0" pref="0" max="32767" attributes="0"/>
<Component id="cancelBtn" min="-2" max="-2" attributes="0"/> <Component id="cancelBtn" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/> <EmptySpace max="-2" attributes="0"/>
<Component id="saveBtn" min="-2" pref="81" max="-2" attributes="0"/> <Component id="saveBtn" min="-2" pref="81" max="-2" attributes="0"/>
</Group> </Group>
<Group type="102" alignment="0" attributes="0">
<Component id="jPanel2" min="-2" max="-2" attributes="0"/>
<EmptySpace type="unrelated" max="-2" attributes="0"/>
<Component id="jPanel3" min="-2" max="-2" attributes="0"/>
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
</Group>
</Group> </Group>
<EmptySpace max="32767" attributes="0"/> <EmptySpace max="-2" attributes="0"/>
</Group> </Group>
</Group> </Group>
</DimensionLayout> </DimensionLayout>
@ -61,13 +63,14 @@
<Group type="103" groupAlignment="0" max="-2" attributes="0"> <Group type="103" groupAlignment="0" max="-2" attributes="0">
<Component id="jPanel1" max="32767" attributes="0"/> <Component id="jPanel1" max="32767" attributes="0"/>
<Component id="jPanel2" max="32767" attributes="0"/> <Component id="jPanel2" max="32767" attributes="0"/>
<Component id="jPanel3" max="32767" attributes="0"/>
</Group> </Group>
<EmptySpace pref="29" max="32767" attributes="0"/> <EmptySpace min="-2" pref="21" max="-2" attributes="0"/>
<Group type="103" groupAlignment="3" attributes="0"> <Group type="103" groupAlignment="3" attributes="0">
<Component id="saveBtn" alignment="3" min="-2" max="-2" attributes="0"/> <Component id="saveBtn" alignment="3" min="-2" max="-2" attributes="0"/>
<Component id="cancelBtn" alignment="3" min="-2" max="-2" attributes="0"/> <Component id="cancelBtn" alignment="3" min="-2" max="-2" attributes="0"/>
</Group> </Group>
<EmptySpace max="-2" attributes="0"/> <EmptySpace pref="15" max="32767" attributes="0"/>
</Group> </Group>
</Group> </Group>
</DimensionLayout> </DimensionLayout>
@ -207,5 +210,42 @@
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="cancelBtnActionPerformed"/> <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="cancelBtnActionPerformed"/>
</Events> </Events>
</Component> </Component>
<Container class="javax.swing.JPanel" name="jPanel3">
<Properties>
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
<Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
<TitledBorder title="Editor"/>
</Border>
</Property>
</Properties>
<Layout>
<DimensionLayout dim="0">
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" alignment="1" attributes="0">
<EmptySpace max="32767" attributes="0"/>
<Component id="advOptionsBox" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
</Group>
</Group>
</DimensionLayout>
<DimensionLayout dim="1">
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" alignment="0" attributes="0">
<EmptySpace max="-2" attributes="0"/>
<Component id="advOptionsBox" min="-2" max="-2" attributes="0"/>
<EmptySpace max="32767" attributes="0"/>
</Group>
</Group>
</DimensionLayout>
</Layout>
<SubComponents>
<Component class="javax.swing.JCheckBox" name="advOptionsBox">
<Properties>
<Property name="text" type="java.lang.String" value="Advanced Options"/>
</Properties>
</Component>
</SubComponents>
</Container>
</SubComponents> </SubComponents>
</Form> </Form>

View File

@ -60,6 +60,8 @@ public class Display extends javax.swing.JInternalFrame {
jLabel1 = new javax.swing.JLabel(); jLabel1 = new javax.swing.JLabel();
saveBtn = new javax.swing.JButton(); saveBtn = new javax.swing.JButton();
cancelBtn = new javax.swing.JButton(); cancelBtn = new javax.swing.JButton();
jPanel3 = new javax.swing.JPanel();
advOptionsBox = new javax.swing.JCheckBox();
setClosable(true); setClosable(true);
setIconifiable(true); setIconifiable(true);
@ -145,24 +147,47 @@ public class Display extends javax.swing.JInternalFrame {
} }
}); });
jPanel3.setBorder(javax.swing.BorderFactory.createTitledBorder("Editor"));
advOptionsBox.setText("Advanced Options");
javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
jPanel3.setLayout(jPanel3Layout);
jPanel3Layout.setHorizontalGroup(
jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel3Layout.createSequentialGroup()
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(advOptionsBox)
.addContainerGap())
);
jPanel3Layout.setVerticalGroup(
jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel3Layout.createSequentialGroup()
.addContainerGap()
.addComponent(advOptionsBox)
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
);
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
getContentPane().setLayout(layout); getContentPane().setLayout(layout);
layout.setHorizontalGroup( layout.setHorizontalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup() .addGroup(layout.createSequentialGroup()
.addContainerGap() .addContainerGap()
.addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(0, 0, Short.MAX_VALUE))
.addGroup(layout.createSequentialGroup() .addGroup(layout.createSequentialGroup()
.addGap(0, 0, Short.MAX_VALUE) .addGap(0, 0, Short.MAX_VALUE)
.addComponent(cancelBtn) .addComponent(cancelBtn)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(saveBtn, javax.swing.GroupLayout.PREFERRED_SIZE, 81, javax.swing.GroupLayout.PREFERRED_SIZE))) .addComponent(saveBtn, javax.swing.GroupLayout.PREFERRED_SIZE, 81, javax.swing.GroupLayout.PREFERRED_SIZE))
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .addGroup(layout.createSequentialGroup()
.addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(jPanel3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(0, 0, Short.MAX_VALUE)))
.addContainerGap())
); );
layout.setVerticalGroup( layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
@ -170,12 +195,13 @@ public class Display extends javax.swing.JInternalFrame {
.addContainerGap() .addContainerGap()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
.addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .addComponent(jPanel2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 29, Short.MAX_VALUE) .addComponent(jPanel3, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
.addGap(21, 21, 21)
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(saveBtn) .addComponent(saveBtn)
.addComponent(cancelBtn)) .addComponent(cancelBtn))
.addContainerGap()) .addContainerGap(15, Short.MAX_VALUE))
); );
pack(); pack();
@ -200,9 +226,9 @@ public class Display extends javax.swing.JInternalFrame {
themeDark.setSelected(false); themeDark.setSelected(false);
} }
} }
// if (PrefStorage.isset("advancedcontrols")) { if (PrefStorage.isset("advancedcontrols")) {
// advOptionsBox.setSelected(true); advOptionsBox.setSelected(true);
// } }
}//GEN-LAST:event_formComponentShown }//GEN-LAST:event_formComponentShown
private void saveBtnActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_saveBtnActionPerformed private void saveBtnActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_saveBtnActionPerformed
@ -212,28 +238,30 @@ public class Display extends javax.swing.JInternalFrame {
} else { } else {
PrefStorage.saveSetting("theme", "light"); PrefStorage.saveSetting("theme", "light");
} }
// if (advOptionsBox.isSelected()) { if (advOptionsBox.isSelected()) {
// PrefStorage.saveSetting("advancedcontrols", "true"); PrefStorage.saveSetting("advancedcontrols", "true");
// } else { } else {
// PrefStorage.unset("advancedcontrols"); PrefStorage.unset("advancedcontrols");
// } }
if (!PrefStorage.save()) { if (!PrefStorage.save()) {
// Something dun goofed... // Something dun goofed...
JOptionPane.showInternalMessageDialog(this, JOptionPane.showInternalMessageDialog(this,
"Error: Problem occured while saving settings. " "Error: Problem occured while saving settings. "
+ "This error is outside the control of " + "This error is outside the control of "
+ "the application."); + "the application.");
} }
MainGUI.updateDisplay(); MainGUI.updateDisplay();
dispose(); dispose();
}//GEN-LAST:event_saveBtnActionPerformed }//GEN-LAST:event_saveBtnActionPerformed
// Variables declaration - do not modify//GEN-BEGIN:variables // Variables declaration - do not modify//GEN-BEGIN:variables
private javax.swing.JCheckBox advOptionsBox;
private javax.swing.JButton cancelBtn; private javax.swing.JButton cancelBtn;
private javax.swing.JComboBox fontSizeBox; private javax.swing.JComboBox fontSizeBox;
private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel1;
private javax.swing.JPanel jPanel1; private javax.swing.JPanel jPanel1;
private javax.swing.JPanel jPanel2; private javax.swing.JPanel jPanel2;
private javax.swing.JPanel jPanel3;
private javax.swing.JButton saveBtn; private javax.swing.JButton saveBtn;
private javax.swing.JRadioButton themeDark; private javax.swing.JRadioButton themeDark;
private javax.swing.ButtonGroup themeGroup; private javax.swing.ButtonGroup themeGroup;

View File

@ -51,20 +51,20 @@ public class Interpreter extends javax.swing.JInternalFrame {
*/ */
public Interpreter(String useLang) { public Interpreter(String useLang) {
initComponents(); initComponents();
// Setup code runner // Setup code runner
lang = useLang; lang = useLang;
if (lang.equals("default")) { if (lang.equals("default")) {
lang = PrefStorage.getSetting("shellLang", "javascript"); lang = PrefStorage.getSetting("shellLang", "javascript");
} }
cr = new CodeRunner(lang, true); cr = new CodeRunner(lang, true);
// Set selected lang menu // Set selected lang menu
if (lang.equals("python")) { if (lang.equals("python")) {
javascriptMenu.setSelected(false); javascriptMenu.setSelected(false);
pythonMenu.setSelected(true); pythonMenu.setSelected(true);
} }
// Set font // Set font
int font_size = 12; int font_size = 12;
try { try {
@ -73,7 +73,7 @@ public class Interpreter extends javax.swing.JInternalFrame {
} }
mainBox.setFont(new Font(Font.MONOSPACED, Font.PLAIN, font_size)); mainBox.setFont(new Font(Font.MONOSPACED, Font.PLAIN, font_size));
inputBox.setFont(new Font(Font.MONOSPACED, Font.PLAIN, font_size)); inputBox.setFont(new Font(Font.MONOSPACED, Font.PLAIN, font_size));
// Set theme // Set theme
if (PrefStorage.getSetting("theme").equals("dark")) { if (PrefStorage.getSetting("theme").equals("dark")) {
mainBox.setBackground(Color.BLACK); mainBox.setBackground(Color.BLACK);
@ -88,7 +88,7 @@ public class Interpreter extends javax.swing.JInternalFrame {
inputBox.setForeground(Color.BLACK); inputBox.setForeground(Color.BLACK);
setBackground(Color.LIGHT_GRAY); setBackground(Color.LIGHT_GRAY);
} }
// Misc. setup // Misc. setup
mainBox.setText(">>"); mainBox.setText(">>");
inputBox.requestFocus(); inputBox.requestFocus();

View File

@ -125,7 +125,7 @@
<Component class="javax.swing.JButton" name="shellBtn"> <Component class="javax.swing.JButton" name="shellBtn">
<Properties> <Properties>
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor"> <Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
<Image iconType="3" name="/net/apocalypselabs/symat/shell.png"/> <Image iconType="3" name="/net/apocalypselabs/symat/images/shell.png"/>
</Property> </Property>
<Property name="text" type="java.lang.String" value="Shell"/> <Property name="text" type="java.lang.String" value="Shell"/>
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor"> <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
@ -145,7 +145,7 @@
<Component class="javax.swing.JButton" name="editorBtn"> <Component class="javax.swing.JButton" name="editorBtn">
<Properties> <Properties>
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor"> <Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
<Image iconType="3" name="/net/apocalypselabs/symat/editor.png"/> <Image iconType="3" name="/net/apocalypselabs/symat/images/editor.png"/>
</Property> </Property>
<Property name="text" type="java.lang.String" value="Editor"/> <Property name="text" type="java.lang.String" value="Editor"/>
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor"> <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
@ -165,7 +165,7 @@
<Component class="javax.swing.JButton" name="graphBtn"> <Component class="javax.swing.JButton" name="graphBtn">
<Properties> <Properties>
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor"> <Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
<Image iconType="3" name="/net/apocalypselabs/symat/graph.png"/> <Image iconType="3" name="/net/apocalypselabs/symat/images/graph.png"/>
</Property> </Property>
<Property name="text" type="java.lang.String" value="Graph"/> <Property name="text" type="java.lang.String" value="Graph"/>
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor"> <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
@ -233,7 +233,7 @@
<Component class="javax.swing.JButton" name="helpBtn"> <Component class="javax.swing.JButton" name="helpBtn">
<Properties> <Properties>
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor"> <Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
<Image iconType="3" name="/net/apocalypselabs/symat/help.png"/> <Image iconType="3" name="/net/apocalypselabs/symat/images/help.png"/>
</Property> </Property>
<Property name="text" type="java.lang.String" value="Manual"/> <Property name="text" type="java.lang.String" value="Manual"/>
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor"> <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
@ -262,7 +262,7 @@
<Component class="javax.swing.JButton" name="arrangeWindowsBtn"> <Component class="javax.swing.JButton" name="arrangeWindowsBtn">
<Properties> <Properties>
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor"> <Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
<Image iconType="3" name="/net/apocalypselabs/symat/cascade.png"/> <Image iconType="3" name="/net/apocalypselabs/symat/images/cascade.png"/>
</Property> </Property>
<Property name="text" type="java.lang.String" value="Cascade"/> <Property name="text" type="java.lang.String" value="Cascade"/>
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor"> <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
@ -282,7 +282,7 @@
<Component class="javax.swing.JButton" name="closeAllBtn"> <Component class="javax.swing.JButton" name="closeAllBtn">
<Properties> <Properties>
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor"> <Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
<Image iconType="3" name="/net/apocalypselabs/symat/closeall.png"/> <Image iconType="3" name="/net/apocalypselabs/symat/images/closeall.png"/>
</Property> </Property>
<Property name="text" type="java.lang.String" value="Close All"/> <Property name="text" type="java.lang.String" value="Close All"/>
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor"> <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
@ -344,7 +344,7 @@
<Component class="javax.swing.JButton" name="displaySettingsBtn"> <Component class="javax.swing.JButton" name="displaySettingsBtn">
<Properties> <Properties>
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor"> <Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
<Image iconType="3" name="/net/apocalypselabs/symat/display.png"/> <Image iconType="3" name="/net/apocalypselabs/symat/images/display.png"/>
</Property> </Property>
<Property name="text" type="java.lang.String" value="Display"/> <Property name="text" type="java.lang.String" value="Display"/>
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor"> <Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">

View File

@ -170,7 +170,7 @@ public class MainGUI extends javax.swing.JFrame {
jPanel1.setOpaque(false); jPanel1.setOpaque(false);
shellBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/shell.png"))); // NOI18N shellBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/images/shell.png"))); // NOI18N
shellBtn.setText("Shell"); shellBtn.setText("Shell");
shellBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); shellBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
shellBtn.setFocusable(false); shellBtn.setFocusable(false);
@ -183,7 +183,7 @@ public class MainGUI extends javax.swing.JFrame {
} }
}); });
editorBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/editor.png"))); // NOI18N editorBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/images/editor.png"))); // NOI18N
editorBtn.setText("Editor"); editorBtn.setText("Editor");
editorBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); editorBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
editorBtn.setFocusable(false); editorBtn.setFocusable(false);
@ -196,7 +196,7 @@ public class MainGUI extends javax.swing.JFrame {
} }
}); });
graphBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/graph.png"))); // NOI18N graphBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/images/graph.png"))); // NOI18N
graphBtn.setText("Graph"); graphBtn.setText("Graph");
graphBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); graphBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
graphBtn.setFocusable(false); graphBtn.setFocusable(false);
@ -242,7 +242,7 @@ public class MainGUI extends javax.swing.JFrame {
jPanel2.setOpaque(false); jPanel2.setOpaque(false);
helpBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/help.png"))); // NOI18N helpBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/images/help.png"))); // NOI18N
helpBtn.setText("Manual"); helpBtn.setText("Manual");
helpBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); helpBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
helpBtn.setFocusable(false); helpBtn.setFocusable(false);
@ -259,7 +259,7 @@ public class MainGUI extends javax.swing.JFrame {
jLabel3.setText(namemark()); jLabel3.setText(namemark());
jLabel3.setFocusable(false); jLabel3.setFocusable(false);
arrangeWindowsBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/cascade.png"))); // NOI18N arrangeWindowsBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/images/cascade.png"))); // NOI18N
arrangeWindowsBtn.setText("Cascade"); arrangeWindowsBtn.setText("Cascade");
arrangeWindowsBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); arrangeWindowsBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
arrangeWindowsBtn.setFocusable(false); arrangeWindowsBtn.setFocusable(false);
@ -272,7 +272,7 @@ public class MainGUI extends javax.swing.JFrame {
} }
}); });
closeAllBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/closeall.png"))); // NOI18N closeAllBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/images/closeall.png"))); // NOI18N
closeAllBtn.setText("Close All"); closeAllBtn.setText("Close All");
closeAllBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); closeAllBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
closeAllBtn.setFocusable(false); closeAllBtn.setFocusable(false);
@ -315,7 +315,7 @@ public class MainGUI extends javax.swing.JFrame {
jLabel4.setText(namemark()); jLabel4.setText(namemark());
jLabel4.setFocusable(false); jLabel4.setFocusable(false);
displaySettingsBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/display.png"))); // NOI18N displaySettingsBtn.setIcon(new javax.swing.ImageIcon(getClass().getResource("/net/apocalypselabs/symat/images/display.png"))); // NOI18N
displaySettingsBtn.setText("Display"); displaySettingsBtn.setText("Display");
displaySettingsBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5)); displaySettingsBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
displaySettingsBtn.setFocusable(false); displaySettingsBtn.setFocusable(false);
@ -494,6 +494,7 @@ public class MainGUI extends javax.swing.JFrame {
//</editor-fold> //</editor-fold>
//</editor-fold> //</editor-fold>
// Command line args // Command line args
for (String arg : args) { for (String arg : args) {
if (arg.equals("skippython")) { if (arg.equals("skippython")) {
@ -502,7 +503,7 @@ public class MainGUI extends javax.swing.JFrame {
argfile = args[0]; argfile = args[0];
} }
} }
/* Create and display the form */ /* Create and display the form */
java.awt.EventQueue.invokeLater(new Runnable() { java.awt.EventQueue.invokeLater(new Runnable() {
@Override @Override

View File

@ -45,7 +45,7 @@ public class PrefStorage {
public static boolean isset(String key) { public static boolean isset(String key) {
return !getSetting(key, "NULL").equals("NULL"); return !getSetting(key, "NULL").equals("NULL");
} }
public static void unset(String key) { public static void unset(String key) {
prefs.remove(key); prefs.remove(key);
} }
@ -57,7 +57,7 @@ public class PrefStorage {
public static String getSetting(String key, String emptyResponse) { public static String getSetting(String key, String emptyResponse) {
return prefs.get(key, emptyResponse); return prefs.get(key, emptyResponse);
} }
public static boolean save() { public static boolean save() {
try { try {
prefs.flush(); prefs.flush();

View File

Before

Width:  |  Height:  |  Size: 920 B

After

Width:  |  Height:  |  Size: 920 B

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

Before

Width:  |  Height:  |  Size: 972 B

After

Width:  |  Height:  |  Size: 972 B

View File

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 1.0 KiB

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB