SetLocalCmd sets an option local to the buffer
(args []string)
| 730 | |
| 731 | // SetLocalCmd sets an option local to the buffer |
| 732 | func (h *BufPane) SetLocalCmd(args []string) { |
| 733 | if len(args) < 2 { |
| 734 | InfoBar.Error("Not enough arguments") |
| 735 | return |
| 736 | } |
| 737 | |
| 738 | option := args[0] |
| 739 | value := args[1] |
| 740 | |
| 741 | err := h.Buf.SetOption(option, value) |
| 742 | if err != nil { |
| 743 | InfoBar.Error(err) |
| 744 | } |
| 745 | } |
| 746 | |
| 747 | func (h *BufPane) toggleOption(option string, local bool) error { |
| 748 | var curVal, newVal any |