mirror of
https://github.com/bancika/diy-layout-creator
synced 2026-11-10 17:22:09 +10:00
4.6.0 release
This commit is contained in:
@@ -3039,7 +3039,7 @@
|
|||||||
<minor>6</minor>
|
<minor>6</minor>
|
||||||
<build>0</build>
|
<build>0</build>
|
||||||
</versionNumber>
|
</versionNumber>
|
||||||
<releaseDate>2020-04-20 00:00:00.000 CET</releaseDate>
|
<releaseDate>2020-05-03 00:00:00.000 CET</releaseDate>
|
||||||
<name></name>
|
<name></name>
|
||||||
<changes>
|
<changes>
|
||||||
<org.diylc.appframework.update.Change>
|
<org.diylc.appframework.update.Change>
|
||||||
@@ -3050,6 +3050,10 @@
|
|||||||
<changeType>NEW_FEATURE</changeType>
|
<changeType>NEW_FEATURE</changeType>
|
||||||
<description>Added "Sizing Mode" to Image component that allows stretching the image freely using two control points</description>
|
<description>Added "Sizing Mode" to Image component that allows stretching the image freely using two control points</description>
|
||||||
</org.diylc.appframework.update.Change>
|
</org.diylc.appframework.update.Change>
|
||||||
|
<org.diylc.appframework.update.Change>
|
||||||
|
<changeType>NEW_FEATURE</changeType>
|
||||||
|
<description>Added "Loadline Editor" to the File menu, to be used in the future to calculate tube or transistor bias point using loadlines</description>
|
||||||
|
</org.diylc.appframework.update.Change>
|
||||||
<org.diylc.appframework.update.Change>
|
<org.diylc.appframework.update.Change>
|
||||||
<changeType>IMPROVEMENT</changeType>
|
<changeType>IMPROVEMENT</changeType>
|
||||||
<description>Include themes and fonts in OSX app package</description>
|
<description>Include themes and fonts in OSX app package</description>
|
||||||
|
|||||||
Binary file not shown.
@@ -36,10 +36,10 @@ import org.diylc.core.annotations.BomPolicy;
|
|||||||
import org.diylc.core.annotations.ComponentDescriptor;
|
import org.diylc.core.annotations.ComponentDescriptor;
|
||||||
import org.diylc.core.annotations.EditableProperty;
|
import org.diylc.core.annotations.EditableProperty;
|
||||||
|
|
||||||
@ComponentDescriptor(name = "Loadline", category = "Misc", author = "Branislav Stojkovic",
|
//@ComponentDescriptor(name = "Loadline", category = "Misc", author = "Branislav Stojkovic",
|
||||||
zOrder = IDIYComponent.BOARD, instanceNamePrefix = "LL",
|
// zOrder = IDIYComponent.BOARD, instanceNamePrefix = "LL",
|
||||||
description = "Loadline of a tube or transistor", bomPolicy = BomPolicy.SHOW_ONLY_TYPE_NAME,
|
// description = "Loadline of a tube or transistor", bomPolicy = BomPolicy.SHOW_ONLY_TYPE_NAME,
|
||||||
autoEdit = false, transformer = SimpleComponentTransformer.class)
|
// autoEdit = false, transformer = SimpleComponentTransformer.class)
|
||||||
public class Loadline extends AbstractBoard {
|
public class Loadline extends AbstractBoard {
|
||||||
|
|
||||||
private static final long serialVersionUID = 1L;
|
private static final long serialVersionUID = 1L;
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
<property name="jar.dir" value="${build.dir}/jar" />
|
<property name="jar.dir" value="${build.dir}/jar" />
|
||||||
<property name="report.dir" value="${build.dir}/junitreport" />
|
<property name="report.dir" value="${build.dir}/junitreport" />
|
||||||
<property name="main.class" value="org.diylc.DIYLCStarter" />
|
<property name="main.class" value="org.diylc.DIYLCStarter" />
|
||||||
<property name="diylc.version" value="4.5.0" />
|
<property name="diylc.version" value="4.6.0" />
|
||||||
|
|
||||||
<property name="classes.dir" value="${build.dir}/temp/${ant.project.name}/classes" />
|
<property name="classes.dir" value="${build.dir}/temp/${ant.project.name}/classes" />
|
||||||
<property name="test.classes.dir" value="${build.dir}/temp/${ant.project.name}/test.classes" />
|
<property name="test.classes.dir" value="${build.dir}/temp/${ant.project.name}/test.classes" />
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
@@ -66,7 +66,7 @@ public enum IconLoader {
|
|||||||
Node("node.png"), Web("web.png"), Guitar("guitar.png"), Scientist("scientist.png"), StarGrey("star_grey.png"), StarBlue("star_blue.png"),
|
Node("node.png"), Web("web.png"), Guitar("guitar.png"), Scientist("scientist.png"), StarGrey("star_grey.png"), StarBlue("star_blue.png"),
|
||||||
JarBeanInto("jar_bean_into.png"), GraphEdgeDirected("graph_edge_directed.png"), LaserPointer("laserpointer.png"), TapeMeasure("tape_measure1.png"),
|
JarBeanInto("jar_bean_into.png"), GraphEdgeDirected("graph_edge_directed.png"), LaserPointer("laserpointer.png"), TapeMeasure("tape_measure1.png"),
|
||||||
Elements("elements1.png"), GraphNodes("graph_nodes.png"), User("user1.png"), FlexibleLeads("flexible_leads.png"), Pads("pads.png"), Lock("lock.png"),
|
Elements("elements1.png"), GraphNodes("graph_nodes.png"), User("user1.png"), FlexibleLeads("flexible_leads.png"), Pads("pads.png"), Lock("lock.png"),
|
||||||
Unlock("lock_open.png"), Earth("earth.png");
|
Unlock("lock_open.png"), Earth("earth.png"), Loadline("loadline.png"), LoadlineAdd("loadline_add.png");
|
||||||
|
|
||||||
protected String name;
|
protected String name;
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 629 B |
Binary file not shown.
|
After Width: | Height: | Size: 648 B |
@@ -105,6 +105,16 @@ public class DialogFactory {
|
|||||||
return processFileChooserResult(result, openFileChooser, defaultExtension);
|
return processFileChooserResult(result, openFileChooser, defaultExtension);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public File showOpenDialog(Window owner, FileFilter fileFilter, File initialFile, String defaultExtension,
|
||||||
|
IFileChooserAccessory accessory) {
|
||||||
|
JFileChooser openFileChooser = new JFileChooser();
|
||||||
|
initializeFileChooser(openFileChooser, fileFilter, initialFile, defaultExtension, accessory, false);
|
||||||
|
|
||||||
|
int result = openFileChooser.showOpenDialog(owner);
|
||||||
|
|
||||||
|
return processFileChooserResult(result, openFileChooser, defaultExtension);
|
||||||
|
}
|
||||||
|
|
||||||
public File showOpenDialog(FileFilter fileFilter, File initialFile, String defaultExtension,
|
public File showOpenDialog(FileFilter fileFilter, File initialFile, String defaultExtension,
|
||||||
IFileChooserAccessory accessory, JFrame ownerFrame) {
|
IFileChooserAccessory accessory, JFrame ownerFrame) {
|
||||||
JFileChooser openFileChooser = new JFileChooser();
|
JFileChooser openFileChooser = new JFileChooser();
|
||||||
|
|||||||
@@ -23,12 +23,14 @@ import java.util.Set;
|
|||||||
|
|
||||||
import javax.swing.AbstractAction;
|
import javax.swing.AbstractAction;
|
||||||
import javax.swing.Action;
|
import javax.swing.Action;
|
||||||
|
import javax.swing.BorderFactory;
|
||||||
import javax.swing.JButton;
|
import javax.swing.JButton;
|
||||||
import javax.swing.JComponent;
|
import javax.swing.JComponent;
|
||||||
import javax.swing.JFrame;
|
import javax.swing.JFrame;
|
||||||
import javax.swing.JLabel;
|
import javax.swing.JLabel;
|
||||||
import javax.swing.JPanel;
|
import javax.swing.JPanel;
|
||||||
import javax.swing.JTextField;
|
import javax.swing.JTextField;
|
||||||
|
import javax.swing.UIManager;
|
||||||
|
|
||||||
import org.apache.log4j.Logger;
|
import org.apache.log4j.Logger;
|
||||||
import org.apache.poi.util.IOUtils;
|
import org.apache.poi.util.IOUtils;
|
||||||
@@ -97,6 +99,8 @@ public class LoadlineEditorFrame extends JFrame implements IView {
|
|||||||
|
|
||||||
public LoadlineEditorFrame() {
|
public LoadlineEditorFrame() {
|
||||||
super("Loadline Editor");
|
super("Loadline Editor");
|
||||||
|
setIconImage(IconLoader.Loadline.getImage());
|
||||||
|
setResizable(false);
|
||||||
|
|
||||||
if (loadline == null) {
|
if (loadline == null) {
|
||||||
loadline = new LoadlineEntity();
|
loadline = new LoadlineEntity();
|
||||||
@@ -174,6 +178,7 @@ public class LoadlineEditorFrame extends JFrame implements IView {
|
|||||||
toolbar.add(new JButton(new SaveAction()));
|
toolbar.add(new JButton(new SaveAction()));
|
||||||
toolbar.add(new JButton(new LoadImageAction()));
|
toolbar.add(new JButton(new LoadImageAction()));
|
||||||
toolbar.add(new JButton(new AddCurveAction()));
|
toolbar.add(new JButton(new AddCurveAction()));
|
||||||
|
toolbar.setBorder(BorderFactory.createMatteBorder(1, 0, 1, 0, UIManager.getColor("InternalFrame.borderShadow")));
|
||||||
}
|
}
|
||||||
return toolbar;
|
return toolbar;
|
||||||
}
|
}
|
||||||
@@ -265,6 +270,7 @@ public class LoadlineEditorFrame extends JFrame implements IView {
|
|||||||
JButton updateButton = new JButton(new UpdateValuesAction());
|
JButton updateButton = new JButton(new UpdateValuesAction());
|
||||||
controlPanel.add(updateButton);
|
controlPanel.add(updateButton);
|
||||||
|
|
||||||
|
controlPanel.setBorder(BorderFactory.createMatteBorder(1, 0, 0, 0, UIManager.getColor("InternalFrame.borderShadow")));
|
||||||
}
|
}
|
||||||
return controlPanel;
|
return controlPanel;
|
||||||
}
|
}
|
||||||
@@ -513,7 +519,7 @@ public class LoadlineEditorFrame extends JFrame implements IView {
|
|||||||
@Override
|
@Override
|
||||||
public boolean editProperties(List<PropertyWrapper> properties,
|
public boolean editProperties(List<PropertyWrapper> properties,
|
||||||
Set<PropertyWrapper> defaultedProperties) {
|
Set<PropertyWrapper> defaultedProperties) {
|
||||||
PropertyEditorDialog editor = DialogFactory.getInstance().createPropertyEditorDialog(properties,
|
PropertyEditorDialog editor = DialogFactory.getInstance().createPropertyEditorDialog(LoadlineEditorFrame.this, properties,
|
||||||
LangUtil.translate("Edit Selection"), true);
|
LangUtil.translate("Edit Selection"), true);
|
||||||
editor.setVisible(true);
|
editor.setVisible(true);
|
||||||
defaultedProperties.addAll(editor.getDefaultedProperties());
|
defaultedProperties.addAll(editor.getDefaultedProperties());
|
||||||
@@ -599,7 +605,7 @@ public class LoadlineEditorFrame extends JFrame implements IView {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void actionPerformed(ActionEvent e) {
|
public void actionPerformed(ActionEvent e) {
|
||||||
final File file = DialogFactory.getInstance().showOpenDialog(FileFilterEnum.CRV.getFilter(), null,
|
final File file = DialogFactory.getInstance().showOpenDialog(LoadlineEditorFrame.this, FileFilterEnum.CRV.getFilter(), null,
|
||||||
FileFilterEnum.CRV.getExtensions()[0], null);
|
FileFilterEnum.CRV.getExtensions()[0], null);
|
||||||
if (file != null) {
|
if (file != null) {
|
||||||
try {
|
try {
|
||||||
@@ -643,7 +649,7 @@ public class LoadlineEditorFrame extends JFrame implements IView {
|
|||||||
public AddCurveAction() {
|
public AddCurveAction() {
|
||||||
super();
|
super();
|
||||||
putValue(Action.NAME, "Add a Curve");
|
putValue(Action.NAME, "Add a Curve");
|
||||||
// putValue(Action.SMALL_ICON, IconLoader.DiskBlue.getIcon());
|
putValue(Action.SMALL_ICON, IconLoader.LoadlineAdd.getIcon());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -664,7 +670,7 @@ public class LoadlineEditorFrame extends JFrame implements IView {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void actionPerformed(ActionEvent e) {
|
public void actionPerformed(ActionEvent e) {
|
||||||
File file = DialogFactory.getInstance().showOpenDialog(FileFilterEnum.IMAGES.getFilter(),
|
File file = DialogFactory.getInstance().showOpenDialog(LoadlineEditorFrame.this, FileFilterEnum.IMAGES.getFilter(),
|
||||||
null, FileFilterEnum.IMAGES.getExtensions()[0], null);
|
null, FileFilterEnum.IMAGES.getExtensions()[0], null);
|
||||||
if (file != null) {
|
if (file != null) {
|
||||||
FileInputStream fis;
|
FileInputStream fis;
|
||||||
@@ -702,7 +708,7 @@ public class LoadlineEditorFrame extends JFrame implements IView {
|
|||||||
public LoadlineEditorAction() {
|
public LoadlineEditorAction() {
|
||||||
super();
|
super();
|
||||||
putValue(Action.NAME, "Loadline Editor");
|
putValue(Action.NAME, "Loadline Editor");
|
||||||
// putValue(Action.SMALL_ICON, IconLoader.Delete.getIcon());
|
putValue(Action.SMALL_ICON, IconLoader.Loadline.getIcon());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -40,7 +40,6 @@ import org.diylc.core.Project;
|
|||||||
import org.diylc.images.IconLoader;
|
import org.diylc.images.IconLoader;
|
||||||
import org.diylc.swing.ActionFactory;
|
import org.diylc.swing.ActionFactory;
|
||||||
import org.diylc.swing.ISwingUI;
|
import org.diylc.swing.ISwingUI;
|
||||||
import org.diylc.swing.loadline.LoadlineEditorFrame;
|
|
||||||
|
|
||||||
public class EditMenuPlugin implements IPlugIn, ClipboardOwner {
|
public class EditMenuPlugin implements IPlugIn, ClipboardOwner {
|
||||||
|
|
||||||
@@ -323,7 +322,6 @@ public class EditMenuPlugin implements IPlugIn, ClipboardOwner {
|
|||||||
swingUI.injectMenuAction(getFlexibleLeadsAction(), EDIT_TITLE);
|
swingUI.injectMenuAction(getFlexibleLeadsAction(), EDIT_TITLE);
|
||||||
swingUI.injectMenuAction(null, EDIT_TITLE);
|
swingUI.injectMenuAction(null, EDIT_TITLE);
|
||||||
swingUI.injectMenuAction(actionFactory.createEditProjectAction(plugInPort), EDIT_TITLE);
|
swingUI.injectMenuAction(actionFactory.createEditProjectAction(plugInPort), EDIT_TITLE);
|
||||||
swingUI.injectMenuAction(new LoadlineEditorFrame.LoadlineEditorAction(), EDIT_TITLE);
|
|
||||||
|
|
||||||
refreshActions();
|
refreshActions();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,6 +36,7 @@ import org.diylc.images.IconLoader;
|
|||||||
import org.diylc.swing.ActionFactory;
|
import org.diylc.swing.ActionFactory;
|
||||||
import org.diylc.swing.IDynamicSubmenuHandler;
|
import org.diylc.swing.IDynamicSubmenuHandler;
|
||||||
import org.diylc.swing.ISwingUI;
|
import org.diylc.swing.ISwingUI;
|
||||||
|
import org.diylc.swing.loadline.LoadlineEditorFrame;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Entry point class for File management utilities.
|
* Entry point class for File management utilities.
|
||||||
@@ -104,6 +105,7 @@ public class FileMenuPlugin implements IPlugIn, IDynamicSubmenuHandler {
|
|||||||
swingUI.injectMenuAction(null, INTEGRATION_TITLE);
|
swingUI.injectMenuAction(null, INTEGRATION_TITLE);
|
||||||
swingUI.injectMenuAction(actionFactory.createImportVariantsAction(swingUI, plugInPort), INTEGRATION_TITLE);
|
swingUI.injectMenuAction(actionFactory.createImportVariantsAction(swingUI, plugInPort), INTEGRATION_TITLE);
|
||||||
swingUI.injectMenuAction(actionFactory.createExportVariantsAction(swingUI, plugInPort), INTEGRATION_TITLE);
|
swingUI.injectMenuAction(actionFactory.createExportVariantsAction(swingUI, plugInPort), INTEGRATION_TITLE);
|
||||||
|
swingUI.injectMenuAction(new LoadlineEditorFrame.LoadlineEditorAction(), FILE_TITLE);
|
||||||
swingUI.injectMenuAction(null, FILE_TITLE);
|
swingUI.injectMenuAction(null, FILE_TITLE);
|
||||||
swingUI.injectMenuAction(actionFactory.createExitAction(plugInPort), FILE_TITLE);
|
swingUI.injectMenuAction(actionFactory.createExitAction(plugInPort), FILE_TITLE);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user