Checkstyle: fix javadoc issues

This commit is contained in:
mkpaz 2023-02-09 20:27:50 +04:00
parent deb27f576a
commit bb7b37caf6
18 changed files with 202 additions and 230 deletions

@ -24,7 +24,7 @@ public abstract class BehaviorBase<C extends Control, S extends SkinBase<C>> {
} }
/** /**
* Called from {@link SkinBase#dispose()} to clean up the behavior state * Called from {@link SkinBase#dispose()} to clean up the behavior state.
*/ */
public void dispose() { public void dispose() {
this.control = null; this.control = null;

@ -51,8 +51,8 @@ import javafx.util.Callback;
/** /**
* Represents a bread crumb bar. This control is useful to visualize and navigate * Represents a bread crumb bar. This control is useful to visualize and navigate
* a hierarchical path structure, such as file systems. * a hierarchical path structure, such as file systems.
* <p> *
* A breadcrumbs consist of two types of elements: a button (default is a hyperlink) * <p>A breadcrumbs consist of two types of elements: a button (default is a hyperlink)
* and a divider (default is for Label). You can customize both by providing the * and a divider (default is for Label). You can customize both by providing the
* corresponding control factory. * corresponding control factory.
*/ */
@ -101,7 +101,7 @@ public class Breadcrumbs<T> extends Control {
/** /**
* Construct a tree model from the flat list which then can be set * Construct a tree model from the flat list which then can be set
* as selectedCrumb node to be shown * as selectedCrumb node to be shown.
*/ */
@SafeVarargs @SafeVarargs
public static <T> BreadCrumbItem<T> buildTreeModel(T... crumbs) { public static <T> BreadCrumbItem<T> buildTreeModel(T... crumbs) {
@ -125,11 +125,10 @@ public class Breadcrumbs<T> extends Control {
* terms of the bread crumb bar). The full path is then being constructed * terms of the bread crumb bar). The full path is then being constructed
* using getParent() of the tree-items. * using getParent() of the tree-items.
* *
* <p> * <p>Consider the following hierarchy:
* Consider the following hierarchy:
* [Root] &gt; [Folder] &gt; [SubFolder] &gt; [file.txt] * [Root] &gt; [Folder] &gt; [SubFolder] &gt; [file.txt]
* <p> *
* To show the above bread crumb bar, you have to set the [file.txt] tree-node as selected crumb. * <p>To show the above bread crumb bar, you have to set the [file.txt] tree-node as selected crumb.
*/ */
public final ObjectProperty<BreadCrumbItem<T>> selectedCrumbProperty() { public final ObjectProperty<BreadCrumbItem<T>> selectedCrumbProperty() {
return selectedCrumb; return selectedCrumb;
@ -171,12 +170,12 @@ public class Breadcrumbs<T> extends Control {
/** /**
* Crumb factory is used to create custom bread crumb instances. * Crumb factory is used to create custom bread crumb instances.
* <code>null</code> is not allowed and will result in a fallback to the default factory. * <code>null</code> is not allowed and will result in a fallback to the default factory.
* <p> *
* <code>BreadCrumbItem<T></code> specifies the tree item for creating bread crumb. Use * <p><code>BreadCrumbItem&lt;T&gt;</code> specifies the tree item for creating bread crumb. Use
* {@link BreadCrumbItem#isFirst()} and {@link BreadCrumbItem#isLast()} to create bread crumb * {@link BreadCrumbItem#isFirst()} and {@link BreadCrumbItem#isLast()} to create bread crumb
* depending on item position. * depending on item position.
* <p> *
* <code>ButtonBase</code> stands for resulting bread crumb node. It CAN NOT be <code>null</code>. * <p><code>ButtonBase</code> stands for resulting bread crumb node. It CAN NOT be <code>null</code>.
*/ */
public final ObjectProperty<Callback<BreadCrumbItem<T>, ButtonBase>> crumbFactoryProperty() { public final ObjectProperty<Callback<BreadCrumbItem<T>, ButtonBase>> crumbFactoryProperty() {
return crumbFactory; return crumbFactory;
@ -199,13 +198,13 @@ public class Breadcrumbs<T> extends Control {
/** /**
* Divider factory is used to create custom divider instances. * Divider factory is used to create custom divider instances.
* <code>null</code> is not allowed and will result in a fallback to the default factory. * <code>null</code> is not allowed and will result in a fallback to the default factory.
* <p> *
* <code>BreadCrumbItem<T></code> specifies the preceding tree item. It can be null, because this way * <p><code>BreadCrumbItem&lt;T&gt;</code> specifies the preceding tree item. It can be null, because this way
* you can insert divider before the first bread crumb, which can be used e.g. for creating a Unix path. * you can insert divider before the first bread crumb, which can be used e.g. for creating a Unix path.
* Use {@link BreadCrumbItem#isFirst()} and {@link BreadCrumbItem#isLast()} to create divider * Use {@link BreadCrumbItem#isFirst()} and {@link BreadCrumbItem#isLast()} to create divider
* depending on item position. * depending on item position.
* <p> *
* <code>? extends Node</code> stands for resulting divider node. It CAN be <code>null</code>, which * <p><code>? extends Node</code> stands for resulting divider node. It CAN be <code>null</code>, which
* means there will be no divider inserted after the specified bread crumb. * means there will be no divider inserted after the specified bread crumb.
*/ */
public final ObjectProperty<Callback<BreadCrumbItem<T>, ? extends Node>> dividerFactoryProperty() { public final ObjectProperty<Callback<BreadCrumbItem<T>, ? extends Node>> dividerFactoryProperty() {

@ -133,7 +133,7 @@ public class BreadcrumbsSkin<T> extends SkinBase<Breadcrumbs<T>> {
} }
/** /**
* Construct a flat list for the crumbs * Construct a flat list for the crumbs.
* *
* @param bottomMost The crumb node at the end of the path * @param bottomMost The crumb node at the end of the path
*/ */
@ -189,7 +189,7 @@ public class BreadcrumbsSkin<T> extends SkinBase<Breadcrumbs<T>> {
} }
/** /**
* Occurs when a bread crumb gets the action event * Occurs when a bread crumb gets the action event.
* *
* @param crumbModel The crumb which received the action event * @param crumbModel The crumb which received the action event
*/ */

@ -56,14 +56,14 @@ import javafx.util.Callback;
* The DatePicker control allows the user to select a date. The calendar is based on either * The DatePicker control allows the user to select a date. The calendar is based on either
* the standard ISO-8601 chronology or any of the other chronology classes defined in the * the standard ISO-8601 chronology or any of the other chronology classes defined in the
* java.time.chrono package. * java.time.chrono package.
* <p> *
* The {@link #valueProperty() value} property represents the currently selected * <p>The {@link #valueProperty() value} property represents the currently selected
* {@link LocalDate}. The default value is null. * {@link LocalDate}. The default value is null.
* <p> *
* The {@link #chronologyProperty() chronology} property specifies a calendar system to be used * <p>The {@link #chronologyProperty() chronology} property specifies a calendar system to be used
* for parsing, displaying, and choosing dates. * for parsing, displaying, and choosing dates.
* <p> *
* The {@link #valueProperty() value} property is always defined in the ISO calendar system, * <p>The {@link #valueProperty() value} property is always defined in the ISO calendar system,
* however, so applications based on a different chronology may use the conversion methods * however, so applications based on a different chronology may use the conversion methods
* provided in the {@link java.time.chrono.Chronology} API to get or set the corresponding * provided in the {@link java.time.chrono.Chronology} API to get or set the corresponding
* {@link java.time.chrono.ChronoLocalDate} value. * {@link java.time.chrono.ChronoLocalDate} value.
@ -164,11 +164,11 @@ public class InlineDatePicker extends Control {
/** /**
* The calendar system used for parsing, displaying, and choosing dates in the DatePicker * The calendar system used for parsing, displaying, and choosing dates in the DatePicker
* control. * control.
* <p> *
* The default is usually {@link IsoChronology} unless provided explicitly * <p>The default is usually {@link IsoChronology} unless provided explicitly
* in the {@link Locale} by use of a Locale calendar extension. * in the {@link Locale} by use of a Locale calendar extension.
* <p> *
* Setting the value to <code>null</code> will restore the default chronology. * <p>Setting the value to <code>null</code> will restore the default chronology.
* *
* @return a property representing the Chronology being used * @return a property representing the Chronology being used
*/ */
@ -200,11 +200,11 @@ public class InlineDatePicker extends Control {
/** /**
* Whether the DatePicker popup should display a column showing week numbers. * Whether the DatePicker popup should display a column showing week numbers.
* <p> *
* The default value is specified in a resource bundle, and depends on the country of the * <p>The default value is specified in a resource bundle, and depends on the country of the
* current locale. * current locale.
* *
* @return true if popup should display a column showing week numbers * @return "true" if popup should display a column showing week numbers
*/ */
public final BooleanProperty showWeekNumbersProperty() { public final BooleanProperty showWeekNumbersProperty() {
if (showWeekNumbers == null) { if (showWeekNumbers == null) {

@ -68,8 +68,8 @@ import javafx.util.Duration;
* window decorations) and an arrow pointing at the owner. Due to the nature of * window decorations) and an arrow pointing at the owner. Due to the nature of
* popup windows the Popover will move around with the parent window when the * popup windows the Popover will move around with the parent window when the
* user drags it. * user drags it.
* <p> *
* The Popover can be detached from the owning node by dragging it away from the * <p>The Popover can be detached from the owning node by dragging it away from the
* owner. It stops displaying an arrow and starts displaying a title and a close * owner. It stops displaying an arrow and starts displaying a title and a close
* icon. * icon.
*/ */
@ -143,8 +143,8 @@ public class Popover extends PopupControl {
/** /**
* The root pane stores the content node of the popover. It is accessible * The root pane stores the content node of the popover. It is accessible
* via this method in order to support proper styling. * via this method in order to support proper styling.
* <p> *
* Example: * <p>Example:
* *
* <pre> * <pre>
* Popover popOver = new Popover(); * Popover popOver = new Popover();
@ -177,7 +177,7 @@ public class Popover extends PopupControl {
} }
/** /**
* Returns the value of the content property * Returns the value of the content property.
* *
* @return the content node * @return the content node
* @see #contentNodeProperty() * @see #contentNodeProperty()
@ -802,7 +802,7 @@ public class Popover extends PopupControl {
} }
/** /**
* All possible arrow locations * All possible arrow locations.
*/ */
public enum ArrowLocation { public enum ArrowLocation {
LEFT_TOP, LEFT_TOP,

@ -50,7 +50,7 @@ public class ToggleSwitch extends Labeled {
} }
/** /**
* Creates a toggle switch with the specified label * Creates a toggle switch with the specified label.
* *
* @param text The label string of the control * @param text The label string of the control
*/ */

@ -103,7 +103,7 @@ public class ToggleSwitchSkin extends SkinBase<ToggleSwitch> {
/** /**
* How many milliseconds it should take for the thumb to go from * How many milliseconds it should take for the thumb to go from
* one edge to the other * one edge to the other.
*/ */
private DoubleProperty thumbMoveAnimationTime = null; private DoubleProperty thumbMoveAnimationTime = null;

@ -4,9 +4,6 @@ package atlantafx.base.theme;
public final class NordDark implements Theme { public final class NordDark implements Theme {
/**
* Initialize a new NordDark
*/
public NordDark() { public NordDark() {
// Default constructor // Default constructor
} }

@ -4,9 +4,6 @@ package atlantafx.base.theme;
public final class NordLight implements Theme { public final class NordLight implements Theme {
/**
* Initialize a new NordLight
*/
public NordLight() { public NordLight() {
// Default constructor // Default constructor
} }

@ -4,9 +4,6 @@ package atlantafx.base.theme;
public final class PrimerDark implements Theme { public final class PrimerDark implements Theme {
/**
* Initialize a new PrimerDark
*/
public PrimerDark() { public PrimerDark() {
// Default constructor // Default constructor
} }

@ -4,9 +4,6 @@ package atlantafx.base.theme;
public final class PrimerLight implements Theme { public final class PrimerLight implements Theme {
/**
* Initialize a new PrimerLight
*/
public PrimerLight() { public PrimerLight() {
// Default constructor // Default constructor
} }

@ -76,9 +76,6 @@ public final class Styles {
public static final String TEXT_MUTED = "text-muted"; public static final String TEXT_MUTED = "text-muted";
public static final String TEXT_SUBTLE = "text-subtle"; public static final String TEXT_SUBTLE = "text-subtle";
/**
* Initialize a new Styles
*/
private Styles() { private Styles() {
// Default constructor // Default constructor
} }

@ -7,32 +7,29 @@ package atlantafx.base.theme;
*/ */
public final class Tweaks { public final class Tweaks {
/**
* Initialize a new Tweaks
*/
private Tweaks() { private Tweaks() {
// Default constructor // Default constructor
} }
/** /**
* Removes or hides dropdown arrow button * Removes or hides dropdown arrow button.
*/ */
public static final String NO_ARROW = "no-arrow"; public static final String NO_ARROW = "no-arrow";
/** /**
* Removes external control borders * Removes external control borders.
*/ */
public static final String EDGE_TO_EDGE = "edge-to-edge"; public static final String EDGE_TO_EDGE = "edge-to-edge";
/** /**
* Alignment * Alignment.
*/ */
public static final String ALIGN_LEFT = "align-left"; public static final String ALIGN_LEFT = "align-left";
public static final String ALIGN_CENTER = "align-center"; public static final String ALIGN_CENTER = "align-center";
public static final String ALIGN_RIGHT = "align-right"; public static final String ALIGN_RIGHT = "align-right";
/** /**
* Forces a control to use alternative icon, if available * Forces a control to use alternative icon, if available.
*/ */
public static final String ALT_ICON = "alt-icon"; public static final String ALT_ICON = "alt-icon";
} }

@ -8,9 +8,6 @@ package atlantafx.base.util;
*/ */
public final class PlatformUtils { public final class PlatformUtils {
/**
* Initialize a new PlatformUtils
*/
private PlatformUtils() { private PlatformUtils() {
// Default constructor // Default constructor
} }

@ -11,11 +11,11 @@ import java.util.function.Consumer;
/** /**
* Simple event bus implementation. * Simple event bus implementation.
* <p> *
* Subscribe and publish events. Events are published in channels distinguished by event type. * <p>Subscribe and publish events. Events are published in channels distinguished by event type.
* Channels can be grouped using an event type hierarchy. * Channels can be grouped using an event type hierarchy.
* <p> *
* You can use the default event bus instance {@link #getInstance}, which is a singleton, * <p>You can use the default event bus instance {@link #getInstance}, which is a singleton,
* or you can create one or multiple instances of {@link DefaultEventBus}. * or you can create one or multiple instances of {@link DefaultEventBus}.
*/ */
@SuppressWarnings({"unchecked", "rawtypes"}) @SuppressWarnings({"unchecked", "rawtypes"})

@ -7,7 +7,7 @@ import java.util.function.Consumer;
public interface EventBus { public interface EventBus {
/** /**
* Subscribe to an event type * Subscribe to an event type.
* *
* @param eventType the event type, can be a super class of all events to subscribe. * @param eventType the event type, can be a super class of all events to subscribe.
* @param subscriber the subscriber which will consume the events. * @param subscriber the subscriber which will consume the events.
@ -33,8 +33,8 @@ public interface EventBus {
/** /**
* Publish an event to all subscribers. * Publish an event to all subscribers.
* <p> *
* The event type is the class of <code>event</code>. The event is published to all consumers which subscribed to * <p>The event type is the class of <code>event</code>. The event is published to all consumers which subscribed to
* this event type or any super class. * this event type or any super class.
* *
* @param event the event. * @param event the event.

@ -1,20 +1,20 @@
/** /**
* MIT License * MIT License
* <p> *
* Copyright (c) 2022 National Geospatial-Intelligence Agency * <p>Copyright (c) 2022 National Geospatial-Intelligence Agency
* Source: https://github.com/ngageoint/color-java * Source: https://github.com/ngageoint/color-java
* <p> *
* Permission is hereby granted, free of charge, to any person obtaining a copy * <p>Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal * of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights * in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is * copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions: * furnished to do so, subject to the following conditions:
* <p> *
* The above copyright notice and this permission notice shall be included in all * <p>The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software. * copies or substantial portions of the Software.
* <p> *
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * <p>THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
@ -34,27 +34,27 @@ package atlantafx.sampler.util;
public class JColor { public class JColor {
/** /**
* Red arithmetic color value * Red arithmetic color value.
*/ */
private float red = 0.0f; private float red = 0.0f;
/** /**
* Green arithmetic color value * Green arithmetic color value.
*/ */
private float green = 0.0f; private float green = 0.0f;
/** /**
* Blue arithmetic color value * Blue arithmetic color value.
*/ */
private float blue = 0.0f; private float blue = 0.0f;
/** /**
* Opacity arithmetic value * Opacity arithmetic value.
*/ */
private float opacity = 1.0f; private float opacity = 1.0f;
/** /**
* Create the color in hex * Create the color in hex.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -65,7 +65,7 @@ public class JColor {
} }
/** /**
* Create the color in hex with an opacity * Create the color in hex with an opacity.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -77,7 +77,7 @@ public class JColor {
} }
/** /**
* Create the color in hex with an alpha * Create the color in hex with an alpha.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -89,7 +89,7 @@ public class JColor {
} }
/** /**
* Create the color with individual hex colors * Create the color with individual hex colors.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -101,7 +101,7 @@ public class JColor {
} }
/** /**
* Create the color with individual hex colors and alpha * Create the color with individual hex colors and alpha.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -115,7 +115,7 @@ public class JColor {
} }
/** /**
* Create the color with individual hex colors and opacity * Create the color with individual hex colors and opacity.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -129,7 +129,7 @@ public class JColor {
} }
/** /**
* Create the color with RGB values * Create the color with RGB values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -141,7 +141,7 @@ public class JColor {
} }
/** /**
* Create the color with RGBA values * Create the color with RGBA values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -154,7 +154,7 @@ public class JColor {
} }
/** /**
* Create the color with RGBA values * Create the color with RGBA values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -167,7 +167,7 @@ public class JColor {
} }
/** /**
* Create the color with arithmetic RGB values * Create the color with arithmetic RGB values.
* *
* @param red red float color inclusively between 0.0 and 1.0 * @param red red float color inclusively between 0.0 and 1.0
* @param green green float color inclusively between 0.0 and 1.0 * @param green green float color inclusively between 0.0 and 1.0
@ -179,7 +179,7 @@ public class JColor {
} }
/** /**
* Create the color with arithmetic RGB values * Create the color with arithmetic RGB values.
* *
* @param red red float color inclusively between 0.0 and 1.0 * @param red red float color inclusively between 0.0 and 1.0
* @param green green float color inclusively between 0.0 and 1.0 * @param green green float color inclusively between 0.0 and 1.0
@ -194,7 +194,7 @@ public class JColor {
/** /**
* Create the color with HSL (hue, saturation, lightness) or HSL (alpha) * Create the color with HSL (hue, saturation, lightness) or HSL (alpha)
* values * values.
* *
* @param hsl HSL array where: 0 = hue, 1 = saturation, 2 = lightness, * @param hsl HSL array where: 0 = hue, 1 = saturation, 2 = lightness,
* optional 3 = alpha * optional 3 = alpha
@ -205,7 +205,7 @@ public class JColor {
} }
/** /**
* Create the color with HSLA (hue, saturation, lightness, alpha) values * Create the color with HSLA (hue, saturation, lightness, alpha) values.
* *
* @param hsl HSL array where: 0 = hue, 1 = saturation, 2 = lightness * @param hsl HSL array where: 0 = hue, 1 = saturation, 2 = lightness
* @param alpha alpha inclusively between 0.0 and 1.0 * @param alpha alpha inclusively between 0.0 and 1.0
@ -216,7 +216,7 @@ public class JColor {
} }
/** /**
* Create the color as a single integer * Create the color as a single integer.
* *
* @param color color integer * @param color color integer
* @return color * @return color
@ -226,14 +226,14 @@ public class JColor {
} }
/** /**
* Default color constructor, opaque black * Default color constructor, opaque black.
*/ */
public JColor() { public JColor() {
} }
/** /**
* Create the color in hex * Create the color in hex.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -243,7 +243,7 @@ public class JColor {
} }
/** /**
* Create the color in hex with an opacity * Create the color in hex with an opacity.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -254,7 +254,7 @@ public class JColor {
} }
/** /**
* Create the color in hex with an alpha * Create the color in hex with an alpha.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -265,7 +265,7 @@ public class JColor {
} }
/** /**
* Create the color with individual hex colors * Create the color with individual hex colors.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -276,7 +276,7 @@ public class JColor {
} }
/** /**
* Create the color with individual hex colors and alpha * Create the color with individual hex colors and alpha.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -288,7 +288,7 @@ public class JColor {
} }
/** /**
* Create the color with individual hex colors and opacity * Create the color with individual hex colors and opacity.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -300,7 +300,7 @@ public class JColor {
} }
/** /**
* Create the color with RGB values * Create the color with RGB values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -311,7 +311,7 @@ public class JColor {
} }
/** /**
* Create the color with RGBA values * Create the color with RGBA values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -323,7 +323,7 @@ public class JColor {
} }
/** /**
* Create the color with RGBA values * Create the color with RGBA values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -335,7 +335,7 @@ public class JColor {
} }
/** /**
* Create the color with arithmetic RGB values * Create the color with arithmetic RGB values.
* *
* @param red red float color inclusively between 0.0 and 1.0 * @param red red float color inclusively between 0.0 and 1.0
* @param green green float color inclusively between 0.0 and 1.0 * @param green green float color inclusively between 0.0 and 1.0
@ -346,7 +346,7 @@ public class JColor {
} }
/** /**
* Create the color with arithmetic RGB values * Create the color with arithmetic RGB values.
* *
* @param red red float color inclusively between 0.0 and 1.0 * @param red red float color inclusively between 0.0 and 1.0
* @param green green float color inclusively between 0.0 and 1.0 * @param green green float color inclusively between 0.0 and 1.0
@ -358,7 +358,7 @@ public class JColor {
} }
/** /**
* Create the color with HSL (hue, saturation, lightness) or HSL (alpha) * Create the color with HSL (hue, saturation, lightness) or HSL (alpha).
* values * values
* *
* @param hsl HSL array where: 0 = hue, 1 = saturation, 2 = lightness, * @param hsl HSL array where: 0 = hue, 1 = saturation, 2 = lightness,
@ -373,7 +373,7 @@ public class JColor {
} }
/** /**
* Create the color with HSLA (hue, saturation, lightness, alpha) values * Create the color with HSLA (hue, saturation, lightness, alpha) values.
* *
* @param hsl HSL array where: 0 = hue, 1 = saturation, 2 = lightness * @param hsl HSL array where: 0 = hue, 1 = saturation, 2 = lightness
* @param alpha alpha inclusively between 0.0 and 1.0 * @param alpha alpha inclusively between 0.0 and 1.0
@ -383,7 +383,7 @@ public class JColor {
} }
/** /**
* Create the color as a single integer * Create the color as a single integer.
* *
* @param color color integer * @param color color integer
*/ */
@ -392,7 +392,7 @@ public class JColor {
} }
/** /**
* Copy constructor * Copy constructor.
* *
* @param color color to copy * @param color color to copy
*/ */
@ -404,7 +404,7 @@ public class JColor {
} }
/** /**
* Set the color in hex * Set the color in hex.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -420,7 +420,7 @@ public class JColor {
} }
/** /**
* Set the color in hex with an opacity * Set the color in hex with an opacity.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -432,7 +432,7 @@ public class JColor {
} }
/** /**
* Set the color in hex with an alpha * Set the color in hex with an alpha.
* *
* @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB, * @param color hex color in format #RRGGBB, RRGGBB, #RGB, RGB, #AARRGGBB,
* AARRGGBB, #ARGB, or ARGB * AARRGGBB, #ARGB, or ARGB
@ -444,7 +444,7 @@ public class JColor {
} }
/** /**
* Set the color with individual hex colors * Set the color with individual hex colors.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -457,7 +457,7 @@ public class JColor {
} }
/** /**
* Set the color with individual hex colors and alpha * Set the color with individual hex colors and alpha.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -470,7 +470,7 @@ public class JColor {
} }
/** /**
* Set the color with individual hex colors and opacity * Set the color with individual hex colors and opacity.
* *
* @param red red hex color in format RR * @param red red hex color in format RR
* @param green green hex color in format GG * @param green green hex color in format GG
@ -483,7 +483,7 @@ public class JColor {
} }
/** /**
* Set the color with RGB values * Set the color with RGB values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -496,7 +496,7 @@ public class JColor {
} }
/** /**
* Set the color with RGBA values * Set the color with RGBA values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -509,7 +509,7 @@ public class JColor {
} }
/** /**
* Set the color with RGBA values * Set the color with RGBA values.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -522,7 +522,7 @@ public class JColor {
} }
/** /**
* Set the color with arithmetic RGB values * Set the color with arithmetic RGB values.
* *
* @param red red float color inclusively between 0.0 and 1.0 * @param red red float color inclusively between 0.0 and 1.0
* @param green green float color inclusively between 0.0 and 1.0 * @param green green float color inclusively between 0.0 and 1.0
@ -535,7 +535,7 @@ public class JColor {
} }
/** /**
* Set the color with arithmetic RGB values * Set the color with arithmetic RGB values.
* *
* @param red red float color inclusively between 0.0 and 1.0 * @param red red float color inclusively between 0.0 and 1.0
* @param green green float color inclusively between 0.0 and 1.0 * @param green green float color inclusively between 0.0 and 1.0
@ -548,7 +548,7 @@ public class JColor {
} }
/** /**
* Set the color with HSL (hue, saturation, lightness) values * Set the color with HSL (hue, saturation, lightness) values.
* *
* @param hue hue value inclusively between 0.0 and 360.0 * @param hue hue value inclusively between 0.0 and 360.0
* @param saturation saturation inclusively between 0.0 and 1.0 * @param saturation saturation inclusively between 0.0 and 1.0
@ -563,7 +563,7 @@ public class JColor {
} }
/** /**
* Set the color with HSLA (hue, saturation, lightness, alpha) values * Set the color with HSLA (hue, saturation, lightness, alpha) values.
* *
* @param hue hue value inclusively between 0.0 and 360.0 * @param hue hue value inclusively between 0.0 and 360.0
* @param saturation saturation inclusively between 0.0 and 1.0 * @param saturation saturation inclusively between 0.0 and 1.0
@ -577,7 +577,7 @@ public class JColor {
} }
/** /**
* Set the color as a single integer * Set the color as a single integer.
* *
* @param color color integer * @param color color integer
*/ */
@ -591,7 +591,7 @@ public class JColor {
} }
/** /**
* Set the red color in hex * Set the red color in hex.
* *
* @param red red hex color in format RR or R * @param red red hex color in format RR or R
*/ */
@ -600,7 +600,7 @@ public class JColor {
} }
/** /**
* Set the green color in hex * Set the green color in hex.
* *
* @param green green hex color in format GG or G * @param green green hex color in format GG or G
*/ */
@ -609,7 +609,7 @@ public class JColor {
} }
/** /**
* Set the blue color in hex * Set the blue color in hex.
* *
* @param blue blue hex color in format BB or B * @param blue blue hex color in format BB or B
*/ */
@ -618,7 +618,7 @@ public class JColor {
} }
/** /**
* Set the alpha color in hex * Set the alpha color in hex.
* *
* @param alpha alpha hex color in format AA or A * @param alpha alpha hex color in format AA or A
*/ */
@ -627,7 +627,7 @@ public class JColor {
} }
/** /**
* Set the red color as an integer * Set the red color as an integer.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
*/ */
@ -636,7 +636,7 @@ public class JColor {
} }
/** /**
* Set the green color as an integer * Set the green color as an integer.
* *
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
*/ */
@ -645,7 +645,7 @@ public class JColor {
} }
/** /**
* Set the blue color as an integer * Set the blue color as an integer.
* *
* @param blue blue integer color inclusively between 0 and 255 * @param blue blue integer color inclusively between 0 and 255
*/ */
@ -654,7 +654,7 @@ public class JColor {
} }
/** /**
* Set the alpha color as an integer * Set the alpha color as an integer.
* *
* @param alpha alpha integer color inclusively between 0 and 255 * @param alpha alpha integer color inclusively between 0 and 255
*/ */
@ -663,7 +663,7 @@ public class JColor {
} }
/** /**
* Set the red color as an arithmetic float * Set the red color as an arithmetic float.
* *
* @param red red float color inclusively between 0.0 and 1.0 * @param red red float color inclusively between 0.0 and 1.0
*/ */
@ -673,7 +673,7 @@ public class JColor {
} }
/** /**
* Set the green color as an arithmetic float * Set the green color as an arithmetic float.
* *
* @param green green float color inclusively between 0.0 and 1.0 * @param green green float color inclusively between 0.0 and 1.0
*/ */
@ -683,7 +683,7 @@ public class JColor {
} }
/** /**
* Set the blue color as an arithmetic float * Set the blue color as an arithmetic float.
* *
* @param blue blue float color inclusively between 0.0 and 1.0 * @param blue blue float color inclusively between 0.0 and 1.0
*/ */
@ -693,7 +693,7 @@ public class JColor {
} }
/** /**
* Set the opacity as an arithmetic float * Set the opacity as an arithmetic float.
* *
* @param opacity opacity float color inclusively between 0.0 and 1.0 * @param opacity opacity float color inclusively between 0.0 and 1.0
*/ */
@ -703,7 +703,7 @@ public class JColor {
} }
/** /**
* Set the alpha color as an arithmetic float * Set the alpha color as an arithmetic float.
* *
* @param alpha alpha float color inclusively between 0.0 and 1.0 * @param alpha alpha float color inclusively between 0.0 and 1.0
*/ */
@ -721,7 +721,7 @@ public class JColor {
} }
/** /**
* Get the color as a hex string * Get the color as a hex string.
* *
* @return hex color in the format #RRGGBB * @return hex color in the format #RRGGBB
*/ */
@ -730,7 +730,7 @@ public class JColor {
} }
/** /**
* Get the color as a hex string with alpha * Get the color as a hex string with alpha.
* *
* @return hex color in the format #AARRGGBB * @return hex color in the format #AARRGGBB
*/ */
@ -740,7 +740,7 @@ public class JColor {
} }
/** /**
* Get the color as a hex string, shorthanded when possible * Get the color as a hex string, shorthanded when possible.
* *
* @return hex color in the format #RGB or #RRGGBB * @return hex color in the format #RGB or #RRGGBB
*/ */
@ -750,7 +750,7 @@ public class JColor {
} }
/** /**
* Get the color as a hex string with alpha, shorthanded when possible * Get the color as a hex string with alpha, shorthanded when possible.
* *
* @return hex color in the format #ARGB or #AARRGGBB * @return hex color in the format #ARGB or #AARRGGBB
*/ */
@ -760,7 +760,7 @@ public class JColor {
} }
/** /**
* Get the color as an integer * Get the color as an integer.
* *
* @return integer color * @return integer color
*/ */
@ -769,7 +769,7 @@ public class JColor {
} }
/** /**
* Get the color as an integer including the alpha * Get the color as an integer including the alpha.
* *
* @return integer color * @return integer color
*/ */
@ -779,7 +779,7 @@ public class JColor {
} }
/** /**
* Get the red color in hex * Get the red color in hex.
* *
* @return red hex color in format RR * @return red hex color in format RR
*/ */
@ -788,7 +788,7 @@ public class JColor {
} }
/** /**
* Get the green color in hex * Get the green color in hex.
* *
* @return green hex color in format GG * @return green hex color in format GG
*/ */
@ -797,7 +797,7 @@ public class JColor {
} }
/** /**
* Get the blue color in hex * Get the blue color in hex.
* *
* @return blue hex color in format BB * @return blue hex color in format BB
*/ */
@ -806,7 +806,7 @@ public class JColor {
} }
/** /**
* Get the alpha color in hex * Get the alpha color in hex.
* *
* @return alpha hex color in format AA * @return alpha hex color in format AA
*/ */
@ -815,7 +815,7 @@ public class JColor {
} }
/** /**
* Get the red color in hex, shorthand when possible * Get the red color in hex, shorthand when possible.
* *
* @return red hex color in format R or RR * @return red hex color in format R or RR
*/ */
@ -824,7 +824,7 @@ public class JColor {
} }
/** /**
* Get the green color in hex, shorthand when possible * Get the green color in hex, shorthand when possible.
* *
* @return green hex color in format G or GG * @return green hex color in format G or GG
*/ */
@ -833,7 +833,7 @@ public class JColor {
} }
/** /**
* Get the blue color in hex, shorthand when possible * Get the blue color in hex, shorthand when possible.
* *
* @return blue hex color in format B or BB * @return blue hex color in format B or BB
*/ */
@ -842,7 +842,7 @@ public class JColor {
} }
/** /**
* Get the alpha color in hex, shorthand when possible * Get the alpha color in hex, shorthand when possible.
* *
* @return alpha hex color in format A or AA * @return alpha hex color in format A or AA
*/ */
@ -851,7 +851,7 @@ public class JColor {
} }
/** /**
* Get the red color as an integer * Get the red color as an integer.
* *
* @return red integer color inclusively between 0 and 255 * @return red integer color inclusively between 0 and 255
*/ */
@ -860,7 +860,7 @@ public class JColor {
} }
/** /**
* Get the green color as an integer * Get the green color as an integer.
* *
* @return green integer color inclusively between 0 and 255 * @return green integer color inclusively between 0 and 255
*/ */
@ -869,7 +869,7 @@ public class JColor {
} }
/** /**
* Get the blue color as an integer * Get the blue color as an integer.
* *
* @return blue integer color inclusively between 0 and 255 * @return blue integer color inclusively between 0 and 255
*/ */
@ -878,7 +878,7 @@ public class JColor {
} }
/** /**
* Get the alpha color as an integer * Get the alpha color as an integer.
* *
* @return alpha integer color inclusively between 0 and 255 * @return alpha integer color inclusively between 0 and 255
*/ */
@ -887,7 +887,7 @@ public class JColor {
} }
/** /**
* Get the red color as an arithmetic float * Get the red color as an arithmetic float.
* *
* @return red float color inclusively between 0.0 and 1.0 * @return red float color inclusively between 0.0 and 1.0
*/ */
@ -896,7 +896,7 @@ public class JColor {
} }
/** /**
* Get the green color as an arithmetic float * Get the green color as an arithmetic float.
* *
* @return green float color inclusively between 0.0 and 1.0 * @return green float color inclusively between 0.0 and 1.0
*/ */
@ -905,7 +905,7 @@ public class JColor {
} }
/** /**
* Get the blue color as an arithmetic float * Get the blue color as an arithmetic float.
* *
* @return blue float color inclusively between 0.0 and 1.0 * @return blue float color inclusively between 0.0 and 1.0
*/ */
@ -914,7 +914,7 @@ public class JColor {
} }
/** /**
* Get the opacity as an arithmetic float * Get the opacity as an arithmetic float.
* *
* @return opacity float inclusively between 0.0 and 1.0 * @return opacity float inclusively between 0.0 and 1.0
*/ */
@ -923,7 +923,7 @@ public class JColor {
} }
/** /**
* Get the alpha color as an arithmetic float * Get the alpha color as an arithmetic float.
* *
* @return alpha float color inclusively between 0.0 and 1.0 * @return alpha float color inclusively between 0.0 and 1.0
*/ */
@ -932,7 +932,7 @@ public class JColor {
} }
/** /**
* Get the HSL (hue, saturation, lightness) values * Get the HSL (hue, saturation, lightness) values.
* *
* @return HSL array where: 0 = hue, 1 = saturation, 2 = lightness * @return HSL array where: 0 = hue, 1 = saturation, 2 = lightness
*/ */
@ -941,7 +941,7 @@ public class JColor {
} }
/** /**
* Get the HSL hue value * Get the HSL hue value.
* *
* @return hue value * @return hue value
*/ */
@ -950,7 +950,7 @@ public class JColor {
} }
/** /**
* Get the HSL saturation value * Get the HSL saturation value.
* *
* @return saturation value * @return saturation value
*/ */
@ -959,7 +959,7 @@ public class JColor {
} }
/** /**
* Get the HSL lightness value * Get the HSL lightness value.
* *
* @return lightness value * @return lightness value
*/ */
@ -968,7 +968,7 @@ public class JColor {
} }
/** /**
* Copy the color * Copy the color.
* *
* @return color copy * @return color copy
*/ */

@ -1,20 +1,20 @@
/** /**
* MIT License * MIT License
* <p> *
* Copyright (c) 2022 National Geospatial-Intelligence Agency * <p>Copyright (c) 2022 National Geospatial-Intelligence Agency
* Source: https://github.com/ngageoint/color-java * Source: https://github.com/ngageoint/color-java
* <p> *
* Permission is hereby granted, free of charge, to any person obtaining a copy * <p>Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal * of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights * in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is * copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions: * furnished to do so, subject to the following conditions:
* <p> *
* The above copyright notice and this permission notice shall be included in all * <p>The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software. * copies or substantial portions of the Software.
* <p> *
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * <p>THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
@ -36,19 +36,19 @@ import javafx.scene.paint.Color;
public class JColorUtils { public class JColorUtils {
/** /**
* Hex color pattern * Hex color pattern.
*/ */
private static final Pattern hexColorPattern = Pattern private static final Pattern hexColorPattern = Pattern
.compile("^#?((\\p{XDigit}{3}){1,2}|(\\p{XDigit}{4}){1,2})$"); .compile("^#?((\\p{XDigit}{3}){1,2}|(\\p{XDigit}{4}){1,2})$");
/** /**
* Hex single color pattern * Hex single color pattern.
*/ */
private static final Pattern hexSingleColorPattern = Pattern private static final Pattern hexSingleColorPattern = Pattern
.compile("^\\p{XDigit}{1,2}$"); .compile("^\\p{XDigit}{1,2}$");
/** /**
* Convert the hex color values to a hex color * Convert the hex color values to a hex color.
* *
* @param red red hex color in format RR or R * @param red red hex color in format RR or R
* @param green green hex color in format GG or G * @param green green hex color in format GG or G
@ -60,7 +60,7 @@ public class JColorUtils {
} }
/** /**
* Convert the hex color values to a hex color, shorthanded when possible * Convert the hex color values to a hex color, shorthanded when possible.
* *
* @param red red hex color in format RR or R * @param red red hex color in format RR or R
* @param green green hex color in format GG or G * @param green green hex color in format GG or G
@ -74,7 +74,7 @@ public class JColorUtils {
/** /**
* Convert the hex color values to a hex color including an opaque alpha * Convert the hex color values to a hex color including an opaque alpha
* value of FF * value of FF.
* *
* @param red red hex color in format RR or R * @param red red hex color in format RR or R
* @param green green hex color in format GG or G * @param green green hex color in format GG or G
@ -93,7 +93,7 @@ public class JColorUtils {
/** /**
* Convert the hex color values to a hex color including an opaque alpha * Convert the hex color values to a hex color including an opaque alpha
* value of FF or F, shorthanded when possible * value of FF or F, shorthanded when possible.
* *
* @param red red hex color in format RR or R * @param red red hex color in format RR or R
* @param green green hex color in format GG or G * @param green green hex color in format GG or G
@ -106,7 +106,7 @@ public class JColorUtils {
} }
/** /**
* Convert the hex color values to a hex color * Convert the hex color values to a hex color.
* *
* @param red red hex color in format RR or R * @param red red hex color in format RR or R
* @param green green hex color in format GG or G * @param green green hex color in format GG or G
@ -132,7 +132,7 @@ public class JColorUtils {
} }
/** /**
* Convert the hex color values to a hex color, shorthanded when possible * Convert the hex color values to a hex color, shorthanded when possible.
* *
* @param red red hex color in format RR or R * @param red red hex color in format RR or R
* @param green green hex color in format GG or G * @param green green hex color in format GG or G
@ -146,7 +146,7 @@ public class JColorUtils {
} }
/** /**
* Convert the RGB values to a color integer * Convert the RGB values to a color integer.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -159,7 +159,7 @@ public class JColorUtils {
/** /**
* Convert the RGB values to a color integer including an opaque alpha value * Convert the RGB values to a color integer including an opaque alpha value
* of 255 * of 255.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -171,7 +171,7 @@ public class JColorUtils {
} }
/** /**
* Convert the RGBA values to a color integer * Convert the RGBA values to a color integer.
* *
* @param red red integer color inclusively between 0 and 255 * @param red red integer color inclusively between 0 and 255
* @param green green integer color inclusively between 0 and 255 * @param green green integer color inclusively between 0 and 255
@ -194,7 +194,7 @@ public class JColorUtils {
} }
/** /**
* Convert the RGB integer to a hex single color * Convert the RGB integer to a hex single color.
* *
* @param color integer color inclusively between 0 and 255 * @param color integer color inclusively between 0 and 255
* @return hex single color in format FF * @return hex single color in format FF
@ -209,7 +209,7 @@ public class JColorUtils {
} }
/** /**
* Convert the arithmetic RGB float to a hex single color * Convert the arithmetic RGB float to a hex single color.
* *
* @param color float color inclusively between 0.0 and 1.0 * @param color float color inclusively between 0.0 and 1.0
* @return hex single color in format FF * @return hex single color in format FF
@ -219,7 +219,7 @@ public class JColorUtils {
} }
/** /**
* Convert the hex single color to an RGB integer * Convert the hex single color to an RGB integer.
* *
* @param color hex single color in format FF or F * @param color hex single color in format FF or F
* @return integer color inclusively between 0 and 255 * @return integer color inclusively between 0 and 255
@ -233,7 +233,7 @@ public class JColorUtils {
} }
/** /**
* Convert the arithmetic RGB float to an RGB integer * Convert the arithmetic RGB float to an RGB integer.
* *
* @param color float color inclusively between 0.0 and 1.0 * @param color float color inclusively between 0.0 and 1.0
* @return integer color inclusively between 0 and 255 * @return integer color inclusively between 0 and 255
@ -244,7 +244,7 @@ public class JColorUtils {
} }
/** /**
* Convert the hex single color to an arithmetic RGB float * Convert the hex single color to an arithmetic RGB float.
* *
* @param color hex single color in format FF or F * @param color hex single color in format FF or F
* @return float color inclusively between 0.0 and 1.0 * @return float color inclusively between 0.0 and 1.0
@ -254,7 +254,7 @@ public class JColorUtils {
} }
/** /**
* Convert the RGB integer to an arithmetic RGB float * Convert the RGB integer to an arithmetic RGB float.
* *
* @param color integer color inclusively between 0 and 255 * @param color integer color inclusively between 0 and 255
* @return float color inclusively between 0.0 and 1.0 * @return float color inclusively between 0.0 and 1.0
@ -266,7 +266,7 @@ public class JColorUtils {
/** /**
* Convert red, green, and blue arithmetic values to HSL (hue, saturation, * Convert red, green, and blue arithmetic values to HSL (hue, saturation,
* lightness) values * lightness) values.
* *
* @param red red color inclusively between 0.0 and 1.0 * @param red red color inclusively between 0.0 and 1.0
* @param green green color inclusively between 0.0 and 1.0 * @param green green color inclusively between 0.0 and 1.0
@ -320,7 +320,7 @@ public class JColorUtils {
/** /**
* Convert red, green, and blue integer values to HSL (hue, saturation, * Convert red, green, and blue integer values to HSL (hue, saturation,
* lightness) values * lightness) values.
* *
* @param red red color inclusively between 0 and 255 * @param red red color inclusively between 0 and 255
* @param green green color inclusively between 0 and 255 * @param green green color inclusively between 0 and 255
@ -334,7 +334,7 @@ public class JColorUtils {
/** /**
* Convert HSL (hue, saturation, and lightness) values to RGB arithmetic * Convert HSL (hue, saturation, and lightness) values to RGB arithmetic
* values * values.
* *
* @param hue hue value inclusively between 0.0 and 360.0 * @param hue hue value inclusively between 0.0 and 360.0
* @param saturation saturation inclusively between 0.0 and 1.0 * @param saturation saturation inclusively between 0.0 and 1.0
@ -365,7 +365,7 @@ public class JColorUtils {
} }
/** /**
* Convert HSL (hue, saturation, and lightness) values to RGB integer values * Convert HSL (hue, saturation, and lightness) values to RGB integer values.
* *
* @param hue hue value inclusively between 0.0 and 360.0 * @param hue hue value inclusively between 0.0 and 360.0
* @param saturation saturation inclusively between 0.0 and 1.0 * @param saturation saturation inclusively between 0.0 and 1.0
@ -378,7 +378,7 @@ public class JColorUtils {
} }
/** /**
* HSL convert helper method * HSL convert helper method.
* *
* @param t1 t1 * @param t1 t1
* @param t2 t2 * @param t2 t2
@ -406,7 +406,7 @@ public class JColorUtils {
} }
/** /**
* Get the hex red color from the hex string * Get the hex red color from the hex string.
* *
* @param hex hex color * @param hex hex color
* @return hex red color in format RR * @return hex red color in format RR
@ -416,7 +416,7 @@ public class JColorUtils {
} }
/** /**
* Get the hex green color from the hex string * Get the hex green color from the hex string.
* *
* @param hex hex color * @param hex hex color
* @return hex green color in format GG * @return hex green color in format GG
@ -426,7 +426,7 @@ public class JColorUtils {
} }
/** /**
* Get the hex blue color from the hex string * Get the hex blue color from the hex string.
* *
* @param hex hex color * @param hex hex color
* @return hex blue color in format BB * @return hex blue color in format BB
@ -436,7 +436,7 @@ public class JColorUtils {
} }
/** /**
* Get the hex alpha color from the hex string if it exists * Get the hex alpha color from the hex string if it exists.
* *
* @param hex hex color * @param hex hex color
* @return hex alpha color in format AA or null * @return hex alpha color in format AA or null
@ -446,7 +446,7 @@ public class JColorUtils {
} }
/** /**
* Get the hex single color * Get the hex single color.
* *
* @param hex hex color * @param hex hex color
* @param colorIndex red=0, green=1, blue=2, alpha=-1 * @param colorIndex red=0, green=1, blue=2, alpha=-1
@ -483,7 +483,7 @@ public class JColorUtils {
} }
/** /**
* Get the red color from color integer * Get the red color from color integer.
* *
* @param color color integer * @param color color integer
* @return red color * @return red color
@ -493,7 +493,7 @@ public class JColorUtils {
} }
/** /**
* Get the green color from color integer * Get the green color from color integer.
* *
* @param color color integer * @param color color integer
* @return green color * @return green color
@ -503,7 +503,7 @@ public class JColorUtils {
} }
/** /**
* Get the blue color from color integer * Get the blue color from color integer.
* *
* @param color color integer * @param color color integer
* @return blue color * @return blue color
@ -513,7 +513,7 @@ public class JColorUtils {
} }
/** /**
* Get the alpha color from color integer * Get the alpha color from color integer.
* *
* @param color color integer * @param color color integer
* @return alpha color * @return alpha color
@ -523,7 +523,7 @@ public class JColorUtils {
} }
/** /**
* Shorthand the hex color if possible * Shorthand the hex color if possible.
* *
* @param color hex color * @param color hex color
* @return shorthand hex color or original value * @return shorthand hex color or original value
@ -555,7 +555,7 @@ public class JColorUtils {
} }
/** /**
* Expand the hex if it is in shorthand * Expand the hex if it is in shorthand.
* *
* @param color hex color * @param color hex color
* @return expanded hex color or original value * @return expanded hex color or original value
@ -580,7 +580,7 @@ public class JColorUtils {
} }
/** /**
* Shorthand the hex single color if possible * Shorthand the hex single color if possible.
* *
* @param color hex single color * @param color hex single color
* @return shorthand hex color or original value * @return shorthand hex color or original value
@ -596,7 +596,7 @@ public class JColorUtils {
} }
/** /**
* Expand the hex single if it is in shorthand * Expand the hex single if it is in shorthand.
* *
* @param color hex single color * @param color hex single color
* @return expanded hex color or original value * @return expanded hex color or original value
@ -610,7 +610,7 @@ public class JColorUtils {
} }
/** /**
* Check if the hex color value is valid * Check if the hex color value is valid.
* *
* @param color hex color * @param color hex color
* @return true if valid * @return true if valid
@ -620,7 +620,7 @@ public class JColorUtils {
} }
/** /**
* Validate the hex color value * Validate the hex color value.
* *
* @param color hex color * @param color hex color
*/ */
@ -633,7 +633,7 @@ public class JColorUtils {
} }
/** /**
* Check if the hex single color value is valid * Check if the hex single color value is valid.
* *
* @param color hex single color * @param color hex single color
* @return true if valid * @return true if valid
@ -643,7 +643,7 @@ public class JColorUtils {
} }
/** /**
* Validate the hex single color value * Validate the hex single color value.
* *
* @param color hex single color * @param color hex single color
*/ */
@ -655,7 +655,7 @@ public class JColorUtils {
} }
/** /**
* Check if the RGB integer color is valid, inclusively between 0 and 255 * Check if the RGB integer color is valid, inclusively between 0 and 255.
* *
* @param color decimal color * @param color decimal color
* @return true if valid * @return true if valid
@ -665,7 +665,7 @@ public class JColorUtils {
} }
/** /**
* Validate the RGB integer color is inclusively between 0 and 255 * Validate the RGB integer color is inclusively between 0 and 255.
* *
* @param color decimal color * @param color decimal color
*/ */
@ -678,8 +678,7 @@ public class JColorUtils {
} }
/** /**
* Check if the arithmetic RGB float color is valid, inclusively between 0.0 * Check if the arithmetic RGB float color is valid, inclusively between 0.0 and 1.0.
* and 1.0
* *
* @param color decimal color * @param color decimal color
* @return true if valid * @return true if valid
@ -689,8 +688,7 @@ public class JColorUtils {
} }
/** /**
* Validate the arithmetic RGB float color is inclusively between 0.0 and * Validate the arithmetic RGB float color is inclusively between 0.0 and 1.0.
* 1.0
* *
* @param color decimal color * @param color decimal color
*/ */
@ -703,8 +701,7 @@ public class JColorUtils {
} }
/** /**
* Check if the HSL hue float value is valid, inclusively between 0.0 and * Check if the HSL hue float value is valid, inclusively between 0.0 and 360.0.
* 360.0
* *
* @param hue hue value * @param hue hue value
* @return true if valid * @return true if valid
@ -727,8 +724,7 @@ public class JColorUtils {
} }
/** /**
* Check if the HSL saturation float value is valid, inclusively between 0.0 * Check if the HSL saturation float value is valid, inclusively between 0.0 and 1.0.
* and 1.0
* *
* @param saturation saturation value * @param saturation saturation value
* @return true if valid * @return true if valid
@ -738,8 +734,7 @@ public class JColorUtils {
} }
/** /**
* Validate the HSL saturation float value is inclusively between 0.0 and * Validate the HSL saturation float value is inclusively between 0.0 and 1.0.
* 1.0
* *
* @param saturation saturation value * @param saturation saturation value
*/ */
@ -752,8 +747,7 @@ public class JColorUtils {
} }
/** /**
* Check if the HSL lightness float value is valid, inclusively between 0.0 * Check if the HSL lightness float value is valid, inclusively between 0.0 and 1.0.
* and 1.0
* *
* @param lightness lightness value * @param lightness lightness value
* @return true if valid * @return true if valid
@ -763,7 +757,7 @@ public class JColorUtils {
} }
/** /**
* Validate the HSL lightness float value is inclusively between 0.0 and 1.0 * Validate the HSL lightness float value is inclusively between 0.0 and 1.0.
* *
* @param lightness lightness value * @param lightness lightness value
*/ */