X-Git-Url: http://git.nikiroo.be/?a=blobdiff_plain;f=src%2Fjexer%2Fbits%2FCellAttributes.java;h=ec3f6ddb6d9518be3302c8aa49ee07a2a0433310;hb=d36057dfab8def933a64be042b039d76708ac5ba;hp=c14557679ee4ff28298021d492b502661ebd0e2a;hpb=eb29bbb5ec70c43895dd0f053630c7e3cd402cba;p=fanfix.git diff --git a/src/jexer/bits/CellAttributes.java b/src/jexer/bits/CellAttributes.java index c145576..ec3f6dd 100644 --- a/src/jexer/bits/CellAttributes.java +++ b/src/jexer/bits/CellAttributes.java @@ -33,11 +33,73 @@ package jexer.bits; */ public class CellAttributes { + // ------------------------------------------------------------------------ + // Variables -------------------------------------------------------------- + // ------------------------------------------------------------------------ + /** * Bold attribute. */ private boolean bold; + /** + * Blink attribute. + */ + private boolean blink; + + /** + * Reverse attribute. + */ + private boolean reverse; + + /** + * Underline attribute. + */ + private boolean underline; + + /** + * Protected attribute. + */ + private boolean protect; + + /** + * Foreground color. Color.WHITE, Color.RED, etc. + */ + private Color foreColor; + + /** + * Background color. Color.WHITE, Color.RED, etc. + */ + private Color backColor; + + // ------------------------------------------------------------------------ + // Constructors ----------------------------------------------------------- + // ------------------------------------------------------------------------ + + /** + * Public constructor sets default values of the cell to white-on-black, + * no bold/blink/reverse/underline/protect. + * + * @see #reset() + */ + public CellAttributes() { + reset(); + } + + /** + * Public constructor makes a copy from another instance. + * + * @param that another CellAttributes instance + * @see #reset() + */ + public CellAttributes(final CellAttributes that) { + setTo(that); + } + + // ------------------------------------------------------------------------ + // CellAttributes --------------------------------------------------------- + // ------------------------------------------------------------------------ + /** * Getter for bold. * @@ -56,11 +118,6 @@ public class CellAttributes { this.bold = bold; } - /** - * Blink attribute. - */ - private boolean blink; - /** * Getter for blink. * @@ -79,11 +136,6 @@ public class CellAttributes { this.blink = blink; } - /** - * Reverse attribute. - */ - private boolean reverse; - /** * Getter for reverse. * @@ -102,11 +154,6 @@ public class CellAttributes { this.reverse = reverse; } - /** - * Underline attribute. - */ - private boolean underline; - /** * Getter for underline. * @@ -125,11 +172,6 @@ public class CellAttributes { this.underline = underline; } - /** - * Protected attribute. - */ - private boolean protect; - /** * Getter for protect. * @@ -148,11 +190,6 @@ public class CellAttributes { this.protect = protect; } - /** - * Foreground color. Color.WHITE, Color.RED, etc. - */ - private Color foreColor; - /** * Getter for foreColor. * @@ -171,11 +208,6 @@ public class CellAttributes { this.foreColor = foreColor; } - /** - * Background color. Color.WHITE, Color.RED, etc. - */ - private Color backColor; - /** * Getter for backColor. * @@ -208,26 +240,6 @@ public class CellAttributes { backColor = Color.BLACK; } - /** - * Public constructor sets default values of the cell to white-on-black, - * no bold/blink/reverse/underline/protect. - * - * @see #reset() - */ - public CellAttributes() { - reset(); - } - - /** - * Public constructor makes a copy from another instance. - * - * @param that another CellAttributes instance - * @see #reset() - */ - public CellAttributes(final CellAttributes that) { - setTo(that); - } - /** * Comparison check. All fields must match to return true. *