This is an automated email from the ASF dual-hosted git repository. desruisseaux pushed a commit to branch visual-test in repository https://gitbox.apache.org/repos/asf/sis.git
commit 93ef45d318fa516fff670bdb0eb54faa6bb9fc1e Author: Martin Desruisseaux <[email protected]> AuthorDate: Wed May 10 22:49:25 2023 +0200 Documentation and warning fixes. --- src/main/java/org/apache/sis/swing/ImagePane.java | 1 + src/main/java/org/apache/sis/swing/SwingUtilities.java | 5 +++-- src/main/java/org/apache/sis/swing/ZoomPane.java | 5 +++-- src/main/java/org/apache/sis/test/visual/DesktopPane.java | 1 + 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/main/java/org/apache/sis/swing/ImagePane.java b/src/main/java/org/apache/sis/swing/ImagePane.java index ee0642fcbb..7f7ce78936 100644 --- a/src/main/java/org/apache/sis/swing/ImagePane.java +++ b/src/main/java/org/apache/sis/swing/ImagePane.java @@ -90,6 +90,7 @@ public class ImagePane extends ZoomPane { * @param title window title. * @return the image pane which has been shown. */ + @SuppressWarnings("UseOfSystemOutOrSystemErr") public static ImagePane show(final GridCoverage coverage, final String title) { final RenderedImage image = coverage.render(null); final GridGeometry gg = (GridGeometry) image.getProperty(PlanarImage.GRID_GEOMETRY_KEY); diff --git a/src/main/java/org/apache/sis/swing/SwingUtilities.java b/src/main/java/org/apache/sis/swing/SwingUtilities.java index 232b09aebb..e2d20fe156 100644 --- a/src/main/java/org/apache/sis/swing/SwingUtilities.java +++ b/src/main/java/org/apache/sis/swing/SwingUtilities.java @@ -265,9 +265,10 @@ final class SwingUtilities extends Static { * Setups the given table for usage as row-header. * This method setups the background color to the same one than the column headers. * - * <div class="note"><b>Note:</b> in a previous version, we were assigning to the row headers + * <h4>Historical note</h4> + * In a previous version, we were assigning to the row headers * the same cell renderer than the one created by <cite>Swing</cite> for the column headers. - * But it produced strange effects when the L&F uses a vertical gradient instead of a uniform color.</div> + * But it produced strange effects when the L&F uses a vertical gradient instead of a uniform color. * * @param table the table to setup as row headers. * @return the renderer which has been assigned to the table. diff --git a/src/main/java/org/apache/sis/swing/ZoomPane.java b/src/main/java/org/apache/sis/swing/ZoomPane.java index 0355670668..d8f6e885d4 100644 --- a/src/main/java/org/apache/sis/swing/ZoomPane.java +++ b/src/main/java/org/apache/sis/swing/ZoomPane.java @@ -721,10 +721,10 @@ public abstract class ZoomPane extends JComponent implements DeformableViewer { * Default implementation makes the <var>y</var> axis orientation upwards and makes the entire content to be * visible in the {@link #getPreferredArea()} logical coordinates. * - * <div class="note"><b>Note:</b> + * <h4>Implementation note</h4> * {@code reset()} is <u>the only</u> {@code ZoomPane} method which does not delegate * to {@link #transform(AffineTransform)} method for modifying the zoom. - * This exception is necessary for avoiding an infinite loop.</div> + * This exception is necessary for avoiding an infinite loop. */ public void reset() { reset(getZoomableBounds(), true); @@ -2323,6 +2323,7 @@ public abstract class ZoomPane extends JComponent implements DeformableViewer { * Prints a message saying "Area:" with coordinates of given rectangle. * This is used for debugging purposes only. */ + @SuppressWarnings("UseOfSystemOutOrSystemErr") private static void debug(final String methodName, final Rectangle2D area) { if (DEBUG) { System.out.println(methodName + " area: " diff --git a/src/main/java/org/apache/sis/test/visual/DesktopPane.java b/src/main/java/org/apache/sis/test/visual/DesktopPane.java index 3daec90fff..c795692323 100644 --- a/src/main/java/org/apache/sis/test/visual/DesktopPane.java +++ b/src/main/java/org/apache/sis/test/visual/DesktopPane.java @@ -135,6 +135,7 @@ final class DesktopPane extends JDesktopPane { /** * Shows the widget created by the given test case. */ + @SuppressWarnings("CallToPrintStackTrace") private void show(final Visualization testCase) { if (autoClose.isSelected()) { closeAllWindows();
