UI tweaks (main menu change to ribbon-style)

This commit is contained in:
skylarmt 2014-12-11 03:18:41 -07:00
parent afd64e2f5b
commit 238505bbca
4 changed files with 296 additions and 126 deletions

View File

@ -174,7 +174,7 @@
</DimensionLayout> </DimensionLayout>
<DimensionLayout dim="1"> <DimensionLayout dim="1">
<Group type="103" groupAlignment="0" attributes="0"> <Group type="103" groupAlignment="0" attributes="0">
<Component id="jSplitPane1" alignment="0" pref="359" max="32767" attributes="0"/> <Component id="jSplitPane1" alignment="0" pref="347" max="32767" attributes="0"/>
</Group> </Group>
</DimensionLayout> </DimensionLayout>
</Layout> </Layout>
@ -226,7 +226,7 @@
<Group type="102" alignment="0" attributes="0"> <Group type="102" alignment="0" attributes="0">
<Component id="jLabel1" min="-2" max="-2" attributes="0"/> <Component id="jLabel1" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/> <EmptySpace max="-2" attributes="0"/>
<Component id="jScrollPane1" pref="72" max="32767" attributes="0"/> <Component id="jScrollPane1" pref="55" max="32767" attributes="0"/>
</Group> </Group>
</Group> </Group>
</DimensionLayout> </DimensionLayout>

View File

@ -173,7 +173,7 @@ public class CodeEditor extends javax.swing.JInternalFrame {
.addGroup(jPanel2Layout.createSequentialGroup() .addGroup(jPanel2Layout.createSequentialGroup()
.addComponent(jLabel1) .addComponent(jLabel1)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 72, Short.MAX_VALUE)) .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 55, Short.MAX_VALUE))
); );
jSplitPane1.setRightComponent(jPanel2); jSplitPane1.setRightComponent(jPanel2);
@ -186,7 +186,7 @@ public class CodeEditor extends javax.swing.JInternalFrame {
); );
jPanel1Layout.setVerticalGroup( jPanel1Layout.setVerticalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(jSplitPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 359, Short.MAX_VALUE) .addComponent(jSplitPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 347, Short.MAX_VALUE)
); );
jMenu1.setText("File"); jMenu1.setText("File");

View File

@ -30,14 +30,14 @@
<DimensionLayout dim="0"> <DimensionLayout dim="0">
<Group type="103" groupAlignment="0" attributes="0"> <Group type="103" groupAlignment="0" attributes="0">
<Component id="mainPane" max="32767" attributes="0"/> <Component id="mainPane" max="32767" attributes="0"/>
<Component id="jToolBar1" alignment="0" max="32767" attributes="0"/> <Component id="tabs" max="32767" attributes="0"/>
</Group> </Group>
</DimensionLayout> </DimensionLayout>
<DimensionLayout dim="1"> <DimensionLayout dim="1">
<Group type="103" groupAlignment="0" attributes="0"> <Group type="103" groupAlignment="0" attributes="0">
<Group type="102" alignment="0" attributes="0"> <Group type="102" alignment="0" attributes="0">
<Component id="jToolBar1" min="-2" pref="63" max="-2" attributes="0"/> <Component id="tabs" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/> <EmptySpace min="0" pref="0" max="-2" attributes="0"/>
<Component id="mainPane" max="32767" attributes="0"/> <Component id="mainPane" max="32767" attributes="0"/>
</Group> </Group>
</Group> </Group>
@ -57,23 +57,60 @@
<Layout> <Layout>
<DimensionLayout dim="0"> <DimensionLayout dim="0">
<Group type="103" groupAlignment="0" attributes="0"> <Group type="103" groupAlignment="0" attributes="0">
<EmptySpace min="0" pref="690" max="32767" attributes="0"/> <EmptySpace min="0" pref="0" max="32767" attributes="0"/>
</Group> </Group>
</DimensionLayout> </DimensionLayout>
<DimensionLayout dim="1"> <DimensionLayout dim="1">
<Group type="103" groupAlignment="0" attributes="0"> <Group type="103" groupAlignment="0" attributes="0">
<EmptySpace min="0" pref="416" max="32767" attributes="0"/> <EmptySpace min="0" pref="407" max="32767" attributes="0"/>
</Group> </Group>
</DimensionLayout> </DimensionLayout>
</Layout> </Layout>
</Container> </Container>
<Container class="javax.swing.JToolBar" name="jToolBar1"> <Container class="javax.swing.JTabbedPane" name="tabs">
<Properties>
<Property name="floatable" type="boolean" value="false"/>
<Property name="rollover" type="boolean" value="true"/>
</Properties>
<Layout class="org.netbeans.modules.form.compat2.layouts.DesignBoxLayout"/> <Layout class="org.netbeans.modules.form.compat2.layouts.support.JTabbedPaneSupportLayout"/>
<SubComponents>
<Container class="javax.swing.JPanel" name="jPanel1">
<Constraints>
<Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.support.JTabbedPaneSupportLayout" value="org.netbeans.modules.form.compat2.layouts.support.JTabbedPaneSupportLayout$JTabbedPaneConstraintsDescription">
<JTabbedPaneConstraints tabName="Apps">
<Property name="tabTitle" type="java.lang.String" value="Apps"/>
</JTabbedPaneConstraints>
</Constraint>
</Constraints>
<Layout>
<DimensionLayout dim="0">
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" attributes="0">
<Component id="shellBtn" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<Component id="editorBtn" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<Component id="graphBtn" min="-2" max="-2" attributes="0"/>
<EmptySpace type="unrelated" max="-2" attributes="0"/>
<Component id="jLabel1" pref="498" max="32767" attributes="0"/>
</Group>
</Group>
</DimensionLayout>
<DimensionLayout dim="1">
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" attributes="0">
<Group type="103" groupAlignment="0" attributes="0">
<Component id="shellBtn" alignment="0" min="-2" max="-2" attributes="0"/>
<Component id="editorBtn" min="-2" max="-2" attributes="0"/>
</Group>
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
</Group>
<Component id="jLabel1" alignment="0" max="32767" attributes="0"/>
<Group type="102" alignment="0" attributes="0">
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
<Component id="graphBtn" min="-2" max="-2" attributes="0"/>
</Group>
</Group>
</DimensionLayout>
</Layout>
<SubComponents> <SubComponents>
<Component class="javax.swing.JButton" name="shellBtn"> <Component class="javax.swing.JButton" name="shellBtn">
<Properties> <Properties>
@ -82,8 +119,8 @@
</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">
<Border info="org.netbeans.modules.form.compat2.border.SoftBevelBorderInfo"> <Border info="org.netbeans.modules.form.compat2.border.EmptyBorderInfo">
<BevelBorder/> <EmptyBorder bottom="5" left="5" right="5" top="5"/>
</Border> </Border>
</Property> </Property>
<Property name="focusable" type="boolean" value="false"/> <Property name="focusable" type="boolean" value="false"/>
@ -102,8 +139,8 @@
</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">
<Border info="org.netbeans.modules.form.compat2.border.SoftBevelBorderInfo"> <Border info="org.netbeans.modules.form.compat2.border.EmptyBorderInfo">
<BevelBorder/> <EmptyBorder bottom="5" left="5" right="5" top="5"/>
</Border> </Border>
</Property> </Property>
<Property name="focusable" type="boolean" value="false"/> <Property name="focusable" type="boolean" value="false"/>
@ -122,8 +159,8 @@
</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">
<Border info="org.netbeans.modules.form.compat2.border.SoftBevelBorderInfo"> <Border info="org.netbeans.modules.form.compat2.border.EmptyBorderInfo">
<BevelBorder/> <EmptyBorder bottom="5" left="5" right="5" top="5"/>
</Border> </Border>
</Property> </Property>
<Property name="focusable" type="boolean" value="false"/> <Property name="focusable" type="boolean" value="false"/>
@ -135,6 +172,49 @@
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="graphBtnActionPerformed"/> <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="graphBtnActionPerformed"/>
</Events> </Events>
</Component> </Component>
<Component class="javax.swing.JLabel" name="jLabel1">
<Properties>
<Property name="horizontalAlignment" type="int" value="11"/>
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor">
<Connection code="namemark()" type="code"/>
</Property>
<Property name="focusable" type="boolean" value="false"/>
</Properties>
</Component>
</SubComponents>
</Container>
<Container class="javax.swing.JPanel" name="jPanel2">
<Constraints>
<Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.support.JTabbedPaneSupportLayout" value="org.netbeans.modules.form.compat2.layouts.support.JTabbedPaneSupportLayout$JTabbedPaneConstraintsDescription">
<JTabbedPaneConstraints tabName="Tools">
<Property name="tabTitle" type="java.lang.String" value="Tools"/>
</JTabbedPaneConstraints>
</Constraint>
</Constraints>
<Layout>
<DimensionLayout dim="0">
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" alignment="0" attributes="0">
<Component id="helpBtn" min="-2" max="-2" attributes="0"/>
<EmptySpace max="-2" attributes="0"/>
<Component id="jLabel3" pref="630" max="32767" attributes="0"/>
</Group>
</Group>
</DimensionLayout>
<DimensionLayout dim="1">
<Group type="103" groupAlignment="0" attributes="0">
<Group type="102" attributes="0">
<Group type="103" groupAlignment="0" attributes="0">
<Component id="helpBtn" min="-2" max="-2" attributes="0"/>
<Component id="jLabel3" min="-2" pref="65" max="-2" attributes="0"/>
</Group>
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
</Group>
</Group>
</DimensionLayout>
</Layout>
<SubComponents>
<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">
@ -142,8 +222,8 @@
</Property> </Property>
<Property name="text" type="java.lang.String" value="Help"/> <Property name="text" type="java.lang.String" value="Help"/>
<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">
<Border info="org.netbeans.modules.form.compat2.border.SoftBevelBorderInfo"> <Border info="org.netbeans.modules.form.compat2.border.EmptyBorderInfo">
<BevelBorder/> <EmptyBorder bottom="5" left="5" right="5" top="5"/>
</Border> </Border>
</Property> </Property>
<Property name="focusable" type="boolean" value="false"/> <Property name="focusable" type="boolean" value="false"/>
@ -155,15 +235,34 @@
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="helpBtnActionPerformed"/> <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="helpBtnActionPerformed"/>
</Events> </Events>
</Component> </Component>
<Component class="javax.swing.JLabel" name="jLabel1"> <Component class="javax.swing.JLabel" name="jLabel3">
<Properties> <Properties>
<Property name="horizontalAlignment" type="int" value="11"/> <Property name="horizontalAlignment" type="int" value="11"/>
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor"> <Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor">
<Connection code="&quot;&lt;html&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style=\&quot;color: gray; font-size: 130%;\&quot;&gt;&lt;i&gt;&quot;+APP_NAME+&quot;&lt;/i&gt;&lt;/span&gt;&quot;" type="code"/> <Connection code="namemark()" type="code"/>
</Property> </Property>
<Property name="focusable" type="boolean" value="false"/>
</Properties> </Properties>
</Component> </Component>
</SubComponents> </SubComponents>
</Container> </Container>
<Component class="javax.swing.JLabel" name="jLabel2">
<Properties>
<Property name="horizontalAlignment" type="int" value="11"/>
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor">
<Connection code="namemark()" type="code"/>
</Property>
<Property name="focusable" type="boolean" value="false"/>
</Properties>
<Constraints>
<Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.support.JTabbedPaneSupportLayout" value="org.netbeans.modules.form.compat2.layouts.support.JTabbedPaneSupportLayout$JTabbedPaneConstraintsDescription">
<JTabbedPaneConstraints tabName="Settings">
<Property name="tabTitle" type="java.lang.String" value="Settings"/>
</JTabbedPaneConstraints>
</Constraint>
</Constraints>
</Component>
</SubComponents>
</Container>
</SubComponents> </SubComponents>
</Form> </Form>

View File

@ -41,8 +41,8 @@ import javax.swing.JInternalFrame;
*/ */
public class MainGUI extends javax.swing.JFrame { public class MainGUI extends javax.swing.JFrame {
public static final String APP_NAME = "SyMAT 0.5.3"; public static final String APP_NAME = "SyMAT 0.6";
public static final double APP_CODE = 0.53; public static final double APP_CODE = 0.6;
public static String argfile = ""; public static String argfile = "";
/** /**
@ -85,6 +85,18 @@ public class MainGUI extends javax.swing.JFrame {
} }
} }
private static String namemark() {
String nbsp = "";
for (int i = 0; i < 8; i++) {
nbsp += "&nbsp;";
}
return "<html>"
+ nbsp
+ "<span style=\"color: gray; font-size: 130%;\"><i>"
+ APP_NAME
+ "</i></span>&nbsp;&nbsp;";
}
/** /**
* This method is called from within the constructor to initialize the form. * This method is called from within the constructor to initialize the form.
* WARNING: Do NOT modify this code. The content of this method is always * WARNING: Do NOT modify this code. The content of this method is always
@ -93,14 +105,19 @@ public class MainGUI extends javax.swing.JFrame {
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() { private void initComponents() {
java.awt.GridBagConstraints gridBagConstraints;
mainPane = new javax.swing.JDesktopPane(); mainPane = new javax.swing.JDesktopPane();
jToolBar1 = new javax.swing.JToolBar(); tabs = new javax.swing.JTabbedPane();
jPanel1 = new javax.swing.JPanel();
shellBtn = new javax.swing.JButton(); shellBtn = new javax.swing.JButton();
editorBtn = new javax.swing.JButton(); editorBtn = new javax.swing.JButton();
graphBtn = new javax.swing.JButton(); graphBtn = new javax.swing.JButton();
helpBtn = new javax.swing.JButton();
jLabel1 = new javax.swing.JLabel(); jLabel1 = new javax.swing.JLabel();
jPanel2 = new javax.swing.JPanel();
helpBtn = new javax.swing.JButton();
jLabel3 = new javax.swing.JLabel();
jLabel2 = new javax.swing.JLabel();
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
setTitle(APP_NAME); setTitle(APP_NAME);
@ -116,19 +133,16 @@ public class MainGUI extends javax.swing.JFrame {
mainPane.setLayout(mainPaneLayout); mainPane.setLayout(mainPaneLayout);
mainPaneLayout.setHorizontalGroup( mainPaneLayout.setHorizontalGroup(
mainPaneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) mainPaneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGap(0, 690, Short.MAX_VALUE) .addGap(0, 0, Short.MAX_VALUE)
); );
mainPaneLayout.setVerticalGroup( mainPaneLayout.setVerticalGroup(
mainPaneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) mainPaneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGap(0, 416, Short.MAX_VALUE) .addGap(0, 407, Short.MAX_VALUE)
); );
jToolBar1.setFloatable(false);
jToolBar1.setRollover(true);
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/shell.png"))); // NOI18N
shellBtn.setText("Shell"); shellBtn.setText("Shell");
shellBtn.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED)); shellBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
shellBtn.setFocusable(false); shellBtn.setFocusable(false);
shellBtn.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); shellBtn.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
shellBtn.setOpaque(false); shellBtn.setOpaque(false);
@ -138,11 +152,10 @@ public class MainGUI extends javax.swing.JFrame {
shellBtnActionPerformed(evt); shellBtnActionPerformed(evt);
} }
}); });
jToolBar1.add(shellBtn);
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/editor.png"))); // NOI18N
editorBtn.setText("Editor"); editorBtn.setText("Editor");
editorBtn.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED)); editorBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
editorBtn.setFocusable(false); editorBtn.setFocusable(false);
editorBtn.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); editorBtn.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
editorBtn.setOpaque(false); editorBtn.setOpaque(false);
@ -152,11 +165,10 @@ public class MainGUI extends javax.swing.JFrame {
editorBtnActionPerformed(evt); editorBtnActionPerformed(evt);
} }
}); });
jToolBar1.add(editorBtn);
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/graph.png"))); // NOI18N
graphBtn.setText("Graph"); graphBtn.setText("Graph");
graphBtn.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED)); graphBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
graphBtn.setFocusable(false); graphBtn.setFocusable(false);
graphBtn.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); graphBtn.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
graphBtn.setOpaque(false); graphBtn.setOpaque(false);
@ -166,11 +178,42 @@ public class MainGUI extends javax.swing.JFrame {
graphBtnActionPerformed(evt); graphBtnActionPerformed(evt);
} }
}); });
jToolBar1.add(graphBtn);
jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
jLabel1.setText(namemark());
jLabel1.setFocusable(false);
javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
jPanel1.setLayout(jPanel1Layout);
jPanel1Layout.setHorizontalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(shellBtn)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(editorBtn)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(graphBtn)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
.addComponent(jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE, 498, Short.MAX_VALUE))
);
jPanel1Layout.setVerticalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(shellBtn)
.addComponent(editorBtn))
.addGap(0, 0, Short.MAX_VALUE))
.addComponent(jLabel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGap(0, 0, Short.MAX_VALUE)
.addComponent(graphBtn))
);
tabs.addTab("Apps", jPanel1);
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/help.png"))); // NOI18N
helpBtn.setText("Help"); helpBtn.setText("Help");
helpBtn.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED)); helpBtn.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
helpBtn.setFocusable(false); helpBtn.setFocusable(false);
helpBtn.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); helpBtn.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
helpBtn.setOpaque(false); helpBtn.setOpaque(false);
@ -180,24 +223,48 @@ public class MainGUI extends javax.swing.JFrame {
helpBtnActionPerformed(evt); helpBtnActionPerformed(evt);
} }
}); });
jToolBar1.add(helpBtn);
jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING); jLabel3.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
jLabel1.setText("<html>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: gray; font-size: 130%;\"><i>"+APP_NAME+"</i></span>"); jLabel3.setText(namemark());
jToolBar1.add(jLabel1); jLabel3.setFocusable(false);
javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
jPanel2.setLayout(jPanel2Layout);
jPanel2Layout.setHorizontalGroup(
jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel2Layout.createSequentialGroup()
.addComponent(helpBtn)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jLabel3, javax.swing.GroupLayout.DEFAULT_SIZE, 630, Short.MAX_VALUE))
);
jPanel2Layout.setVerticalGroup(
jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel2Layout.createSequentialGroup()
.addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(helpBtn)
.addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 65, javax.swing.GroupLayout.PREFERRED_SIZE))
.addGap(0, 0, Short.MAX_VALUE))
);
tabs.addTab("Tools", jPanel2);
jLabel2.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);
jLabel2.setText(namemark());
jLabel2.setFocusable(false);
tabs.addTab("Settings", jLabel2);
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)
.addComponent(mainPane) .addComponent(mainPane)
.addComponent(jToolBar1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(tabs)
); );
layout.setVerticalGroup( layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup() .addGroup(layout.createSequentialGroup()
.addComponent(jToolBar1, javax.swing.GroupLayout.PREFERRED_SIZE, 63, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(tabs, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGap(0, 0, 0)
.addComponent(mainPane)) .addComponent(mainPane))
); );
@ -219,15 +286,15 @@ public class MainGUI extends javax.swing.JFrame {
loadFrame(g); loadFrame(g);
}//GEN-LAST:event_graphBtnActionPerformed }//GEN-LAST:event_graphBtnActionPerformed
private void formComponentShown(java.awt.event.ComponentEvent evt) {//GEN-FIRST:event_formComponentShown
setLocationRelativeTo(null);
}//GEN-LAST:event_formComponentShown
private void helpBtnActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_helpBtnActionPerformed private void helpBtnActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_helpBtnActionPerformed
Help h = new Help(); Help h = new Help();
loadFrame(h); loadFrame(h);
}//GEN-LAST:event_helpBtnActionPerformed }//GEN-LAST:event_helpBtnActionPerformed
private void formComponentShown(java.awt.event.ComponentEvent evt) {//GEN-FIRST:event_formComponentShown
setLocationRelativeTo(null);
}//GEN-LAST:event_formComponentShown
public static void loadFrame(JInternalFrame frame) { public static void loadFrame(JInternalFrame frame) {
mainPane.add(frame); mainPane.add(frame);
frame.setLocation( frame.setLocation(
@ -278,8 +345,12 @@ public class MainGUI extends javax.swing.JFrame {
private javax.swing.JButton graphBtn; private javax.swing.JButton graphBtn;
private javax.swing.JButton helpBtn; private javax.swing.JButton helpBtn;
private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel1;
private javax.swing.JToolBar jToolBar1; private javax.swing.JLabel jLabel2;
private javax.swing.JLabel jLabel3;
private javax.swing.JPanel jPanel1;
private javax.swing.JPanel jPanel2;
public static javax.swing.JDesktopPane mainPane; public static javax.swing.JDesktopPane mainPane;
private javax.swing.JButton shellBtn; private javax.swing.JButton shellBtn;
private javax.swing.JTabbedPane tabs;
// End of variables declaration//GEN-END:variables // End of variables declaration//GEN-END:variables
} }