FileSystemView
classin packageklyn.gui.terminal
public class FileSystemView extends ScrollView:
└ Widget
└ FileSystemView
File-system panel showing current folder entries. When attached through `Terminal.addDockedPane(...)`, it is rendered as an overlay above the active page instead of resizing the page underneath.
Fields
Modifier and Type Member Description
public currentPath
currentPath as String = "."
Current directory displayed in this panel.
public entries
entries as ArrayList<String> = []
Sorted names for current directory.
public scrollIndex
scrollIndex as Int = 0
No summary.
public selectedIndex
selectedIndex as Int = 0
Selected row index in `entries`.
Attributes inherited from ScrollView: scrollOffset
Attributes inherited from Widget: lastRenderAnsi, lastRenderHeight, lastRenderPlain, lastRenderWidth, layout, visible
Properties inherited from ScrollView: text
Properties inherited from Widget: lastRenderFrame, position, size
Properties inherited from Object: type
Constructors
Modifier and Type Member Description
public FileSystemView
FileSystemView(path as String = "."):
No summary.
Methods
Modifier and Type Member Description
public consumePendingOpen
consumePendingOpen() as EditorView:
Consumes a pending open request produced by a double-click.
public goParent
goParent() as Void:
Moves to parent folder when possible.
public override handleMouseEvent
handleMouseEvent(mouse as MouseEvent, localX as Int, localY as Int, viewWidth as Int, viewHeight as Int) as Boolean:
Handles mouse selection and double-click opening inside this file-system view.
public handleVerticalScrollbarMouse
handleVerticalScrollbarMouse(mouse as MouseEvent, localX as Int, localY as Int, viewWidth as Int, viewHeight as Int, totalLines as Int, topInset as Int = 0, bottomInset as Int = 0, rightInset as Int = 0) as Boolean:
No summary.
public openSelected
openSelected() as EditorView:
Opens selected entry.
public pageDown
pageDown() as Void:
No summary.
public pageUp
pageUp() as Void:
No summary.
public override paintToFrame
paintToFrame(frame as TerminalFrame, row as Int, col as Int, panelWidth as Int, panelHeight as Int) as Boolean:
No summary.
public override refresh
refresh() as Void:
Refreshes displayed directory entries.
public scrollBy
scrollBy(delta as Int, viewHeight as Int) as Boolean:
No summary.
public scrollToTrackRow
scrollToTrackRow(trackRow as Int, totalLines as Int, viewHeight as Int, topInset as Int = 0, bottomInset as Int = 0) as Boolean:
No summary.
public scrollbarThumbSize
scrollbarThumbSize(totalLines as Int, viewHeight as Int, topInset as Int = 0, bottomInset as Int = 0) as Int:
No summary.
public scrollbarThumbTop
scrollbarThumbTop(totalLines as Int, viewHeight as Int, topInset as Int = 0, bottomInset as Int = 0) as Int:
No summary.
public selectAtPanelPosition
selectAtPanelPosition(panelRow as Int, panelCol as Int, panelWidth as Int, panelHeight as Int) as Boolean:
Selects an entry from a click inside the rendered panel coordinates.
public selectNext
selectNext() as Void:
Selects the next entry.
public selectPrevious
selectPrevious() as Void:
Selects the previous entry.
Methods inherited from ScrollView: appendLine, clampScrollOffsetFor, clear, contentWidth, hasVerticalScrollbar, maxScrollOffsetFor, paintToFrame, scrollByAmount, scrollbarColumn, toString, visibleRowCount
Methods inherited from Widget: add, baseAnsiStyle, captureRenderFrame, children, clearChildren, handleEvent, handleMouseEvent, paint, paintToFrame, performLayout, refresh, renderAnsiSnapshot, renderPlainSnapshot, scrollbarThumbGlyph, scrollbarTrackGlyph
Methods inherited from Object: fromJson, toDict, toJson, toString, toXml