package com.quicktravel.ticket_printer;

public class TicketElement {
  
  private int x = 0;
  private int y = 0;
  private int fontSize = 10;
  private boolean bold = false;
  private boolean italic = false;
  private String value = "";

  public boolean isImage() {
     return this.value.startsWith("image:");
  }
  
  public int getX() {
    return x;
  }

  public void setX(int x) {
    this.x = x;
  }

  public int getY() {
    return y;
  }

  public void setY(int y) {
    this.y = y;
  }

  public int getFontSize() {
    return fontSize;
  }

  public void setFontSize(int fontSize) {
    this.fontSize = fontSize;
  }

  public boolean isBold() {
    return bold;
  }

  public void setBold(boolean bold) {
    this.bold = bold;
  }

  public boolean isItalic() {
    return italic;
  }

  public void setItalic(boolean italic) {
    this.italic = italic;
  }

  public String getValue() {
    return value;
  }

  public String getImageValue() {
    return this.value.substring(6);
  }
  
  public void setValue(String value) {
    this.value = value;
  }

    
}

@@ -63,18 +63,16 @@
 ement %7B%0A
-  
 %0A  priva
@@ -102,24 +102,55 @@
  int y = 0;%0A
+  protected String value = %22%22;%0A
   private in
@@ -236,118 +236,8 @@
 se;%0A
-  private String value = %22%22;%0A%0A  public boolean isImage() %7B%0A     return this.value.startsWith(%22image:%22);%0A  %7D%0A  
 %0A  p
@@ -405,32 +405,403 @@
 his.y = y;%0A  %7D%0A%0A
+  public String getValue() %7B%0A    return value;%0A  %7D%0A%0A  public void setValue(String value) %7B%0A    this.value = value;%0A  %7D%0A%0A  public boolean isImage() %7B%0A    return isImageUrl() %7C%7C isImageBase64();%0A  %7D%0A%0A  public boolean isImageUrl() %7B%0A     return this.value.startsWith(%22image:%22);%0A  %7D%0A%0A  public boolean isImageBase64() %7B%0A     return this.value.startsWith(%22imageBase64:%22);%0A  %7D%0A%0A
   public int get
@@ -1162,60 +1162,8 @@
  %7D%0A%0A
-  public String getValue() %7B%0A    return value;%0A  %7D%0A%0A
   pu
@@ -1236,82 +1236,6 @@
   %7D%0A
-  %0A  public void setValue(String value) %7B%0A    this.value = value;%0A  %7D%0A%0A    %0A%7D
 %0A
+%7D

Add imageBase64: prefix alongside image: for ticket element values