Methods Summary |
---|
public java.awt.Color | getBackground()
return super.getBackground();
|
public java.awt.Font | getFont()
return super.getFont();
|
public java.awt.Color | getFontColor()
return super.getForeground();
|
public int | getStyle()
return style;
|
public boolean | getUseMonthString()
return useMonthString;
|
public void | setBackground(java.awt.Color newBackground)
super.setBackground(newBackground);
|
public void | setFont(java.awt.Font newFont)
super.setFont(newFont);
|
public void | setFontColor(java.awt.Color newFontColor)
super.setForeground(newFontColor);
|
public void | setStyle(int newStyle)
style = newStyle;
switch(style){
case MONTH_DAY_YEAR:
if(useMonthString)
this.setText(month_str + " " + day + ", " + year);
else
this.setText(month + " / " + day + " / " + year);
break;
case MONTH_DAY_YEAR_ERA:
if(useMonthString)
this.setText(month_str + " " + day + ", " + year + " " + era);
else
this.setText(month + " / " + day + " / " + year + " " + era);
break;
case YEAR_MONTH_DAY:
if(useMonthString)
this.setText(year + " " + month_str + " " + day);
else
this.setText(year + " / " + month + " / " + day);
break;
case MONTH_YEAR:
if(useMonthString)
this.setText(month_str + " " + year);
else
this.setText(month + " " + year);
break;
case DAY_MONTH_YEAR:
if(useMonthString)
this.setText(day + " " + month_str + " " + year);
else
this.setText(day + " / " + month + " / " + year);
break;
default:
this.setText("invalid");
}
|
public void | setUseMonthString(boolean x)
useMonthString = x;
this.setStyle(this.getStyle());
|