Changed the order of the Theme.Pattern method
This commit is contained in:
@@ -24,7 +24,7 @@ func (Default) FontFace (style FontStyle, size FontSize, c Case) font.Face {
|
||||
}
|
||||
|
||||
// Icon returns an icon from the default set corresponding to the given name.
|
||||
func (Default) Icon (string, Case, IconSize) canvas.Image {
|
||||
func (Default) Icon (string, IconSize, Case) canvas.Image {
|
||||
// TODO
|
||||
return nil
|
||||
}
|
||||
@@ -33,8 +33,8 @@ func (Default) Icon (string, Case, IconSize) canvas.Image {
|
||||
// pattern ID.
|
||||
func (Default) Pattern (
|
||||
pattern Pattern,
|
||||
c Case,
|
||||
state PatternState,
|
||||
c Case,
|
||||
) artist.Pattern {
|
||||
switch pattern {
|
||||
case PatternAccent:
|
||||
|
||||
@@ -66,7 +66,7 @@ type Theme interface {
|
||||
|
||||
// Pattern returns an appropriate pattern given a pattern name, case,
|
||||
// and state.
|
||||
Pattern (Pattern, Case, PatternState) artist.Pattern
|
||||
Pattern (Pattern, PatternState, Case) artist.Pattern
|
||||
|
||||
// Inset returns the area on all sides of a given pattern that is not
|
||||
// meant to be drawn on.
|
||||
@@ -101,7 +101,7 @@ func (wrapped Wrapped) Icon (name string, size IconSize) canvas.Image {
|
||||
// Pattern returns an appropriate pattern given a pattern name and state.
|
||||
func (wrapped Wrapped) Pattern (id Pattern, state PatternState) artist.Pattern {
|
||||
real := wrapped.ensure()
|
||||
return real.Pattern(id, wrapped.Case, state)
|
||||
return real.Pattern(id, state, wrapped.Case)
|
||||
}
|
||||
|
||||
// Inset returns the area on all sides of a given pattern that is not meant to
|
||||
|
||||
Reference in New Issue
Block a user