Skip to content

Commit

Permalink
svgom: deprecate a few interfaces
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosame committed Jul 27, 2024
1 parent c128033 commit 172fe27
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 12 deletions.
4 changes: 2 additions & 2 deletions svgom-api/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ dependencies {

description = 'io.sf.carte:svgom-api'

version = '1.0.1'
version = '1.1'

publishing.publications.maven(MavenPublication).pom {
description = "SVGOM 1.0 API Java binding"
description = "SVGOM 1.1 API Java binding"
}
31 changes: 21 additions & 10 deletions svgom-api/src/main/java/org/w3c/dom/svg/SVGColor.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,33 @@
import org.w3c.dom.css.CSSValue;
import org.w3c.dom.css.RGBColor;

/**
* Corresponds to color value definition for properties ‘stop-color’,
* ‘flood-color’ and ‘lighting-color’.
*/
@Deprecated(forRemoval = true)
public interface SVGColor extends CSSValue {

// Color Types
public static final short SVG_COLORTYPE_UNKNOWN = 0;
public static final short SVG_COLORTYPE_RGBCOLOR = 1;
public static final short SVG_COLORTYPE_RGBCOLOR_ICCCOLOR = 2;
public static final short SVG_COLORTYPE_CURRENTCOLOR = 3;
short SVG_COLORTYPE_UNKNOWN = 0;
short SVG_COLORTYPE_RGBCOLOR = 1;
short SVG_COLORTYPE_RGBCOLOR_ICCCOLOR = 2;
short SVG_COLORTYPE_CURRENTCOLOR = 3;

short getColorType();

public short getColorType();
default RGBColor getRGBColor() {
return null;
}

public RGBColor getRGBColor();
default SVGICCColor getICCColor() {
return null;
}

public SVGICCColor getICCColor();
void setRGBColor(String rgbColor) throws SVGException;

public void setRGBColor(String rgbColor) throws SVGException;
void setRGBColorICCColor(String rgbColor, String iccColor) throws SVGException;

public void setRGBColorICCColor(String rgbColor, String iccColor) throws SVGException;
void setColor(short colorType, String rgbColor, String iccColor) throws SVGException;

public void setColor(short colorType, String rgbColor, String iccColor) throws SVGException;
}
4 changes: 4 additions & 0 deletions svgom-api/src/main/java/org/w3c/dom/svg/SVGICCColor.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@

import org.w3c.dom.DOMException;

/**
* Expresses an ICC-based color specification.
*/
@Deprecated(forRemoval = true)
public interface SVGICCColor {
public String getColorProfile();

Expand Down
5 changes: 5 additions & 0 deletions svgom-api/src/main/java/org/w3c/dom/svg/SVGPaint.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@

package org.w3c.dom.svg;

/**
* Corresponds to basic type <paint> and represents the values of properties
* ‘fill’ and ‘stroke’.
*/
@Deprecated
public interface SVGPaint extends SVGColor {
// Paint Types
public static final short SVG_PAINTTYPE_UNKNOWN = 0;
Expand Down

0 comments on commit 172fe27

Please sign in to comment.