(delta int)
| 22 | } |
| 23 | |
| 24 | func (m *FontMenu) Move(delta int) { |
| 25 | m.Cursor += delta |
| 26 | if m.Cursor < 0 { |
| 27 | m.Cursor = len(TextModes) - 1 |
| 28 | } |
| 29 | if m.Cursor >= len(TextModes) { |
| 30 | m.Cursor = 0 |
| 31 | } |
| 32 | } |
| 33 | |
| 34 | func (m *FontMenu) Selected() TextStyleMode { return TextModes[m.Cursor] } |
| 35 |
no outgoing calls
no test coverage detected