MCPcopy
hub / github.com/micro-editor/micro / SetOptionNative

Method SetOptionNative

internal/buffer/settings.go:141–150  ·  view source on GitHub ↗
(option string, nativeValue any)

Source from the content-addressed store, hash-verified

139}
140
141func (b *Buffer) SetOptionNative(option string, nativeValue any) error {
142 if err := config.OptionIsValid(option, nativeValue); err != nil {
143 return err
144 }
145
146 b.DoSetOptionNative(option, nativeValue)
147 b.LocalSettings[option] = true
148
149 return nil
150}
151
152// SetOption sets a given option to a value just for this buffer
153func (b *Buffer) SetOption(option, value string) error {

Callers 6

SetOptionMethod · 0.95
ToggleDiffGutterMethod · 0.80
ToggleRulerMethod · 0.80
openHelpMethod · 0.80
SetGlobalOptionNativeFunction · 0.80
toggleOptionMethod · 0.80

Calls 2

DoSetOptionNativeMethod · 0.95
OptionIsValidFunction · 0.92

Tested by

no test coverage detected