MCPcopy Index your code
hub / github.com/WireGuard/wireguard-windows / SetText

Method SetText

ui/syntax/syntaxedit.go:64–73  ·  view source on GitHub ↗
(text string)

Source from the content-addressed store, hash-verified

62}
63
64func (se *SyntaxEdit) SetText(text string) (err error) {
65 if text == se.Text() {
66 return nil
67 }
68 text = strings.Replace(text, "\n", "\r\n", -1)
69 if win.TRUE != se.SendMessage(win.WM_SETTEXT, 0, uintptr(unsafe.Pointer(syscall.StringToUTF16Ptr(text)))) {
70 err = errors.New("WM_SETTEXT failed")
71 }
72 return
73}
74
75func (se *SyntaxEdit) TextChanged() *walk.Event {
76 return se.textChangedPublisher.Event()

Callers 15

NewSyntaxEditFunction · 0.95
NewUpdatePageFunction · 0.80
NewTunnelsPageFunction · 0.80
CreateToolbarMethod · 0.80
onTunnelsChangedMethod · 0.80
NewLogPageFunction · 0.80
onCopyMethod · 0.80
setupMethod · 0.80
addTunnelActionMethod · 0.80
rebalanceTunnelsMenuMethod · 0.80
updateGlobalStateMethod · 0.80

Calls 1

TextMethod · 0.95

Tested by

no test coverage detected