public interface GutterHandler
Modifier and Type | Method and Description |
---|---|
default void |
handleChangeWidth(Gutter gutter,
int gutterWidth)
Called when the gutter width is changed.
|
boolean |
handleClick(Gutter gutter,
int mouseButton,
int x,
int y)
Called for a click on the gutter.
|
void |
handleMoved(Gutter gutter,
int x,
int y)
Called for a mouse moved on the gutter.
|
boolean |
isPainting(int lineNumber)
Return true if the GutterHandler should paint a specific element on the gutter for a line number.
|
void |
paint(java.awt.Graphics gfx,
int lineNumber,
int x,
int y)
Paint a specific element on the gutter for a line number.
|
boolean isPainting(int lineNumber)
lineNumber
- the line numberboolean handleClick(Gutter gutter, int mouseButton, int x, int y)
MouseEvent.BUTTON1
for left button clickMouseEvent.BUTTON2
for middle button clickMouseEvent.BUTTON3
for right button clickgutter
- the guttermouseButton
- the mouse button.x
- the x positiony
- the y positionvoid handleMoved(Gutter gutter, int x, int y)
gutter
- the gutterx
- the x positiony
- the y positiondefault void handleChangeWidth(Gutter gutter, int gutterWidth)
gutter
- the guttergutterWidth
- the gutter widthvoid paint(java.awt.Graphics gfx, int lineNumber, int x, int y)
gfx
- the GraphicslineNumber
- the line numberx
- the x position of the line numbery
- the y position of the line numberCopyright © 2016, 2017, 2018, 2019, 2023 Herve Girod. All Rights Reserved. Documentation and source under the MIT licence