public class DayEventsViewStyle extends Object
DayEventsView
.Constructor and Description |
---|
DayEventsViewStyle(CalendarDayView owner)
Constructor
|
Modifier and Type | Method and Description |
---|---|
int |
getBackgroundColor()
Gets the background color for day events view.
|
int |
getBottomOffset()
Gets a value in pixels representing the space after the last line that is drawn.
|
long |
getEndTime()
Gets a value in milliseconds representing the ending time of the visible area for events.
|
int |
getEventsOffsetEnd()
Gets a value in pixels representing the offset after the event views
in
DayEventsView . |
int |
getEventsOffsetStart()
Gets a value in pixels representing the offset before the event views
in
DayEventsView and after the time labels. |
int |
getEventsSpacing()
Gets a value in pixels that should be used between the events in
the
DayEventsView . |
int |
getMinEventHeight()
Gets a value in pixels that defines what is the minimum height of an event.
|
long |
getStartTime()
Gets a value in milliseconds representing the starting time of the visible area for events.
|
int |
getTimeLabelColor()
Gets the text color of the time labels in
DayEventsView . |
SimpleDateFormat |
getTimeLabelFormat()
Gets the format for the time labels in
DayEventsView . |
int |
getTimeLabelOffsetEnd()
Gets a value in pixels representing the offset after the time labels
in
DayEventsView before the start of the area with lines and Views. |
int |
getTimeLabelOffsetStart()
Gets a value in pixels representing the offset before the time labels
in
DayEventsView . |
int |
getTimeLabelTextSize()
Gets a value in pixels representing the text size of the time labels in
DayEventsView . |
int |
getTimeLinesColor()
Gets the color used to draw the lines between the time intervals in
DayEventsView . |
long |
getTimeLinesInterval()
Gets a value in milliseconds representing the interval of time between two time lines in
DayEventsView . |
int |
getTimeLinesOffsetEnd()
Gets a value in pixels representing the offset after the time lines
in
DayEventsView . |
int |
getTimeLinesOffsetStart()
Gets a value in pixels representing the offset before the time lines
in
DayEventsView and after the time labels. |
int |
getTimeLinesSpacing()
Gets a value in pixels representing the interval of space between two time lines in
DayEventsView . |
boolean |
getTimeLinesVisible()
Gets a value indicating whether the time lines will be visible in
DayEventsView . |
int |
getTimeLinesWidth()
Gets a value in pixels representing the width of the time lines
in
DayEventsView . |
int |
getTopOffset()
Gets a value in pixels representing the space before the first line that is drawn.
|
void |
setBackgroundColor(int backgroundColor)
Sets the background color for day events view.
|
void |
setBottomOffset(int bottomOffset)
Sets a value in pixels representing the space after the last line that is drawn.
|
void |
setEndTime(long endTime)
Sets a value in milliseconds representing the ending time of the visible area for events.
|
void |
setEventsOffsetEnd(int eventsOffsetEnd)
Sets a value in pixels representing the offset after the event views
in
DayEventsView . |
void |
setEventsOffsetStart(int eventsOffsetStart)
Sets a value in pixels representing the offset before the event views
in
DayEventsView and after the time labels. |
void |
setEventsSpacing(int eventsSpacing)
Sets a value in pixels that will be used between the all day events in
the
DayEventsView . |
void |
setMinEventHeight(int minEventHeight)
Sets a value in pixels that defines what is the minimum height of an event.
|
void |
setStartTime(long startTime)
Sets a value in milliseconds representing the starting time of the visible area for events.
|
void |
setTimeLabelColor(int timeLabelColor)
Sets the text color of the time labels in
DayEventsView . |
void |
setTimeLabelFormat(SimpleDateFormat timeLabelFormat)
Sets a format for the time labels in
DayEventsView . |
void |
setTimeLabelOffsetEnd(int timeLabelOffsetEnd)
Sets a value in pixels representing the offset after the time labels
in
DayEventsView before the start of the area with lines and Views. |
void |
setTimeLabelOffsetStart(int timeLabelOffsetStart)
Sets a value in pixels representing the offset before the time labels
in
DayEventsView . |
void |
setTimeLabelTextSize(int timeLabelTextSize)
Sets a value in pixels representing the text size of the time labels in
DayEventsView . |
void |
setTimeLinesColor(int timeLinesColor)
Sets the color used to draw the lines between the time intervals in
DayEventsView . |
void |
setTimeLinesInterval(long timeLinesInterval)
Sets a value in milliseconds representing the interval of time between two time lines in
DayEventsView . |
void |
setTimeLinesOffsetEnd(int timeLinesOffsetEnd)
Sets a value in pixels representing the offset after the time lines
in
DayEventsView . |
void |
setTimeLinesOffsetStart(int timeLinesOffsetStart)
Sets a value in pixels representing the offset before the time lines
in
DayEventsView and after the time labels. |
void |
setTimeLinesSpacing(int timeLinesSpacing)
Sets a value in pixels representing the interval of space between two time lines in
DayEventsView . |
void |
setTimeLinesVisible(boolean timeLinesVisible)
Sets a value indicating whether the time lines should be visible in
DayEventsView . |
void |
setTimeLinesWidth(int timeLinesWidth)
Sets a value in pixels representing the width of the time lines
in
DayEventsView . |
void |
setTopOffset(int topOffset)
Sets a value in pixels representing the space before the first line that is drawn.
|
public DayEventsViewStyle(CalendarDayView owner)
owner
- the dayView that will use this stylepublic int getBackgroundColor()
CalendarDayViewItem.makeDayEventsView(Context)
public void setBackgroundColor(int backgroundColor)
backgroundColor
- the day views container background colorCalendarDayViewItem.makeDayEventsView(Context)
public long getTimeLinesInterval()
DayEventsView
.
Default value is the amount of milliseconds in one hour (60 * 60 * 1000).CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLinesInterval(long timeLinesInterval)
DayEventsView
.
Default value is the amount of milliseconds in one hour (60 * 60 * 1000).timeLinesInterval
- the new interval between time linesCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLinesSpacing()
DayEventsView
.
Default value is converted from dips depending on the current device's density.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLinesSpacing(int timeLinesSpacing)
DayEventsView
.
Default value is converted from dips depending on the current device's density.timeLinesSpacing
- the new distance between time linesCalendarDayViewItem.makeDayEventsView(Context)
public long getStartTime()
CalendarDayViewItem.makeDayEventsView(Context)
public void setStartTime(long startTime)
startTime
- the new start time for visible eventsIllegalArgumentException
- if the value of start time is
less than 0 or if it is more than the value of endTimeCalendarDayViewItem.makeDayEventsView(Context)
public long getEndTime()
CalendarDayViewItem.makeDayEventsView(Context)
public void setEndTime(long endTime)
endTime
- the new end time for visible eventsIllegalArgumentException
- if the value of end time exceeds the milliseconds in
24 hours or if it is less than the value of startTimeCalendarDayViewItem.makeDayEventsView(Context)
public int getTopOffset()
CalendarDayViewItem.makeDayEventsView(Context)
public void setTopOffset(int topOffset)
topOffset
- the new top offsetCalendarDayViewItem.makeDayEventsView(Context)
public int getBottomOffset()
CalendarDayViewItem.makeDayEventsView(Context)
public void setBottomOffset(int bottomOffset)
bottomOffset
- the new bottom offsetCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLabelTextSize()
DayEventsView
.
Default value is converted from dips depending on the current device's density.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLabelTextSize(int timeLabelTextSize)
DayEventsView
.
Default value is converted from dips depending on the current device's density.timeLabelTextSize
- the new text size of the time labelsCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLabelColor()
DayEventsView
.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLabelColor(int timeLabelColor)
DayEventsView
.timeLabelColor
- the new text color of the time labelsCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLabelOffsetEnd()
DayEventsView
before the start of the area with lines and Views.
Default value is converted from dips depending on the current device's density.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLabelOffsetEnd(int timeLabelOffsetEnd)
DayEventsView
before the start of the area with lines and Views.
Default value is converted from dips depending on the current device's density.timeLabelOffsetEnd
- the new offset after the time labelsCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLabelOffsetStart()
DayEventsView
.
Default value is converted from dips depending on the current device's density.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLabelOffsetStart(int timeLabelOffsetStart)
DayEventsView
.
Default value is converted from dips depending on the current device's density.timeLabelOffsetStart
- the new offset before the time labelsCalendarDayViewItem.makeDayEventsView(Context)
public SimpleDateFormat getTimeLabelFormat()
DayEventsView
.
Default value is created from the following format string:
"h a" and the current locale of the calendar.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLabelFormat(SimpleDateFormat timeLabelFormat)
DayEventsView
.
Default value is created from the following format string:
"h a" and the current locale of the calendar.timeLabelFormat
- the new time labels formatCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLinesColor()
DayEventsView
.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLinesColor(int timeLinesColor)
DayEventsView
.timeLinesColor
- the new time lines colorCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLinesWidth()
DayEventsView
.
Default value is `0` which draws lines in hairline mode.
Hairlines always draws a single pixel independent of the canvas' matrix.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLinesWidth(int timeLinesWidth)
DayEventsView
.
Default value is `0` which draws lines in hairline mode.
Hairlines always draws a single pixel independent of the canvas' matrix.timeLinesWidth
- the new width of the time linesCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLinesOffsetEnd()
DayEventsView
.
Default value is converted from dips depending on the current device's density.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLinesOffsetEnd(int timeLinesOffsetEnd)
DayEventsView
.
Default value is converted from dips depending on the current device's density.timeLinesOffsetEnd
- the new offset after the time linesCalendarDayViewItem.makeDayEventsView(Context)
public int getTimeLinesOffsetStart()
DayEventsView
and after the time labels.
Default value is converted from dips depending on the current device's density.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLinesOffsetStart(int timeLinesOffsetStart)
DayEventsView
and after the time labels.
Default value is converted from dips depending on the current device's density.timeLinesOffsetStart
- the new offset before the time linesCalendarDayViewItem.makeDayEventsView(Context)
public boolean getTimeLinesVisible()
DayEventsView
.
Default value is `true`.CalendarDayViewItem.makeDayEventsView(Context)
public void setTimeLinesVisible(boolean timeLinesVisible)
DayEventsView
.
Default value is `true`.timeLinesVisible
- whether time lines are currently visibleCalendarDayViewItem.makeDayEventsView(Context)
public int getEventsOffsetStart()
DayEventsView
and after the time labels.
Default value is converted from dips depending on the current device's density.CalendarDayViewItem.makeDayEventsView(Context)
public void setEventsOffsetStart(int eventsOffsetStart)
DayEventsView
and after the time labels.
Default value is converted from dips depending on the current device's density.eventsOffsetStart
- the new offset before the event viewsCalendarDayViewItem.makeDayEventsView(Context)
public int getEventsOffsetEnd()
DayEventsView
.
Default value is converted from dips depending on the current device's density.CalendarDayViewItem.makeDayEventsView(Context)
public void setEventsOffsetEnd(int eventsOffsetEnd)
DayEventsView
.
Default value is converted from dips depending on the current device's density.eventsOffsetEnd
- the new offset after the event viewsCalendarDayViewItem.makeDayEventsView(Context)
public int getEventsSpacing()
DayEventsView
.CalendarDayViewItem.makeDayEventsView(Context)
public void setEventsSpacing(int eventsSpacing)
DayEventsView
.eventsSpacing
- the spacing between day events viewsCalendarDayViewItem.makeDayEventsView(Context)
public int getMinEventHeight()
CalendarDayViewItem.makeDayEventsView(Context)
public void setMinEventHeight(int minEventHeight)
minEventHeight
- the minimum height of an eventCalendarDayViewItem.makeDayEventsView(Context)