mirror of
https://github.com/zyedidia/micro.git
synced 2026-03-09 14:20:16 +09:00
Add colorscheme support for selection color
This commit is contained in:
@@ -402,8 +402,12 @@ func (v *View) Display() {
|
||||
if v.cursor.HasSelection() &&
|
||||
(charNum >= v.cursor.selectionStart && charNum <= v.cursor.selectionEnd ||
|
||||
charNum <= v.cursor.selectionStart && charNum >= v.cursor.selectionEnd) {
|
||||
lineStyle = tcell.StyleDefault
|
||||
lineStyle = lineStyle.Reverse(true)
|
||||
|
||||
lineStyle = tcell.StyleDefault.Reverse(true)
|
||||
|
||||
if _, ok := colorscheme["selection"]; ok {
|
||||
lineStyle = colorscheme["selection"]
|
||||
}
|
||||
} else {
|
||||
lineStyle = highlightStyle
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user