MCPcopy Index your code
hub / github.com/lxn/walk / NewPushButton

Function NewPushButton

pushbutton.go:17–35  ·  view source on GitHub ↗
(parent Container)

Source from the content-addressed store, hash-verified

15}
16
17func NewPushButton(parent Container) (*PushButton, error) {
18 pb := new(PushButton)
19
20 if err := InitWidget(
21 pb,
22 parent,
23 "BUTTON",
24 win.WS_TABSTOP|win.WS_VISIBLE|win.BS_PUSHBUTTON,
25 0); err != nil {
26 return nil, err
27 }
28
29 pb.Button.init()
30
31 pb.GraphicsEffects().Add(InteractionEffect)
32 pb.GraphicsEffects().Add(FocusEffect)
33
34 return pb, nil
35}
36
37func (pb *PushButton) ImageAboveText() bool {
38 return pb.hasStyleBits(win.BS_TOP)

Callers

nothing calls this directly

Calls 4

InitWidgetFunction · 0.85
GraphicsEffectsMethod · 0.65
initMethod · 0.45
AddMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…