From: hansonr Date: Fri, 18 Jan 2019 08:57:57 +0000 (-0600) Subject: canvas line/font/pixel fixes; menu accelerators; X-Git-Tag: Release_2_11_4_0~45^2~18^2~314 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=31b84e9690b026255a488724ef7b847da94e48af;p=jalview.git canvas line/font/pixel fixes; menu accelerators; --- diff --git a/src/jalview/bin/Jalview.java b/src/jalview/bin/Jalview.java index 807105a..4684f01 100755 --- a/src/jalview/bin/Jalview.java +++ b/src/jalview/bin/Jalview.java @@ -41,6 +41,8 @@ import jalview.util.MessageManager; import jalview.util.Platform; import jalview.ws.jws2.Jws2Discoverer; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; import java.io.BufferedReader; import java.io.File; import java.io.FileOutputStream; @@ -65,6 +67,7 @@ import java.util.logging.Level; import java.util.logging.Logger; import javax.swing.LookAndFeel; +import javax.swing.Timer; import javax.swing.UIManager; import groovy.lang.Binding; @@ -210,7 +213,7 @@ public class Jalview // setLogging(); // BH - for event debugging in JavaScript instance = new Jalview(); instance.doMain(args); - } +} private static void logClass(String name) { diff --git a/src/jalview/bin/JalviewJS2.java b/src/jalview/bin/JalviewJS2.java index 516cc20..eff5334 100644 --- a/src/jalview/bin/JalviewJS2.java +++ b/src/jalview/bin/JalviewJS2.java @@ -1,5 +1,10 @@ package jalview.bin; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; + +import javax.swing.Timer; + /** * Entry point for JalviewJS development. * @@ -33,6 +38,31 @@ public class JalviewJS2 public static void main(String[] args) throws Exception { Jalview.main(args); + showFocusTimer(); +} + +protected static int focusTime = 0; + +private static void showFocusTimer() { + + Timer t = new Timer(100, new ActionListener() { + + @Override + public void actionPerformed(ActionEvent e) { + String s = /** @j2sNative document.activeElement.id || */ + null; + + s += " " + (++focusTime); + + /** @j2sNative document.title = s; */ + } + + }); + + t.setRepeats(true); + if (/** @j2sNative true || */ + false) + t.start(); } diff --git a/src/jalview/gui/AlignFrame.java b/src/jalview/gui/AlignFrame.java index c1edeab..71ba94a 100644 --- a/src/jalview/gui/AlignFrame.java +++ b/src/jalview/gui/AlignFrame.java @@ -337,7 +337,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener, */ void init() { - setBackground(Color.white); // BH 2019 +// setBackground(Color.white); // BH 2019 if (!Jalview.isHeadlessMode()) { diff --git a/src/jalview/gui/AlignmentPanel.java b/src/jalview/gui/AlignmentPanel.java index 9ae5b8b..0ea2b8a 100644 --- a/src/jalview/gui/AlignmentPanel.java +++ b/src/jalview/gui/AlignmentPanel.java @@ -116,7 +116,7 @@ public class AlignmentPanel extends GAlignmentPanel implements */ public AlignmentPanel(AlignFrame af, final AlignViewport av) { - setBackground(Color.white); // BH 2019 +// setBackground(Color.white); // BH 2019 alignFrame = af; this.av = av; setSeqPanel(new SeqPanel(av, this)); diff --git a/src/jalview/gui/AnnotationPanel.java b/src/jalview/gui/AnnotationPanel.java index 71b7eac..3212156 100755 --- a/src/jalview/gui/AnnotationPanel.java +++ b/src/jalview/gui/AnnotationPanel.java @@ -149,7 +149,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI, */ public AnnotationPanel(AlignmentPanel ap) { - setBackground(Color.white); // BH 2019 +// setBackground(Color.white); // BH 2019 ToolTipManager.sharedInstance().registerComponent(this); ToolTipManager.sharedInstance().setInitialDelay(0); diff --git a/src/jalview/jbgui/GAlignmentPanel.java b/src/jalview/jbgui/GAlignmentPanel.java index bf4f645..29a0cc0 100755 --- a/src/jalview/jbgui/GAlignmentPanel.java +++ b/src/jalview/jbgui/GAlignmentPanel.java @@ -62,6 +62,9 @@ public class GAlignmentPanel extends JPanel static JPanel newJPanel() { // BH 2019 JPanel p = new JPanel(); + // leaving this in, as it prevents + // the checkerboard business, despite how + // funky that looks. Remove if you want to. p.setBackground(Color.white); return p; } @@ -90,7 +93,7 @@ public class GAlignmentPanel extends JPanel private void jbInit() throws Exception { - annotationScroller.setBackground(Color.white); // BH 2019 + // annotationScroller.setBackground(Color.white); // BH 2019 border1 = BorderFactory.createLineBorder(Color.gray, 1); idPanelHolder.setBorder(null); diff --git a/swingjs/SwingJS-site.zip b/swingjs/SwingJS-site.zip index 998fe42..6291264 100644 Binary files a/swingjs/SwingJS-site.zip and b/swingjs/SwingJS-site.zip differ diff --git a/swingjs/net.sf.j2s.core.jar b/swingjs/net.sf.j2s.core.jar index bc730ea..56c61d0 100644 Binary files a/swingjs/net.sf.j2s.core.jar and b/swingjs/net.sf.j2s.core.jar differ diff --git a/swingjs/timestamp b/swingjs/timestamp index 12b8bac..7c45c3c 100644 --- a/swingjs/timestamp +++ b/swingjs/timestamp @@ -1 +1 @@ -20190114011334 +20190118024414 diff --git a/swingjs/ver/3.2.4/SwingJS-site.zip b/swingjs/ver/3.2.4/SwingJS-site.zip index 998fe42..6291264 100644 Binary files a/swingjs/ver/3.2.4/SwingJS-site.zip and b/swingjs/ver/3.2.4/SwingJS-site.zip differ diff --git a/swingjs/ver/3.2.4/net.sf.j2s.core.jar b/swingjs/ver/3.2.4/net.sf.j2s.core.jar index bc730ea..56c61d0 100644 Binary files a/swingjs/ver/3.2.4/net.sf.j2s.core.jar and b/swingjs/ver/3.2.4/net.sf.j2s.core.jar differ diff --git a/swingjs/ver/3.2.4/timestamp b/swingjs/ver/3.2.4/timestamp index 12b8bac..7c45c3c 100644 --- a/swingjs/ver/3.2.4/timestamp +++ b/swingjs/ver/3.2.4/timestamp @@ -1 +1 @@ -20190114011334 +20190118024414