MCPcopy Create free account
hub / github.com/mhammond/pywin32 / PyCButton_set_state

Function PyCButton_set_state

Pythonwin/win32control.cpp:170–184  ·  view source on GitHub ↗

@pymethod int|PyCButton|SetState|Sets the state of the button.

Source from the content-addressed store, hash-verified

168}
169// @pymethod int|PyCButton|SetState|Sets the state of the button.
170static PyObject *
171PyCButton_set_state(PyObject *self, PyObject *args)
172{
173 int state;
174 if (!PyArg_ParseTuple(args, "i", &state)) // @pyparm int|bHighlight||The new state for the button.
175 return NULL;
176 CButton *pBut = GetButton(self);
177 if (!pBut)
178 return NULL;
179 GUI_BGN_SAVE;
180 pBut->SetState(state);
181 GUI_END_SAVE;
182 return Py_BuildValue("i", state);
183 // @comm Highlighting affects the exterior of a button control. It has no effect on the check state of a radio button or check box.
184}
185// @pymethod int|PyCButton|GetButtonStyle|Gets the style of the button.
186static PyObject *
187PyCButton_get_style(PyObject *self, PyObject *args)

Callers

nothing calls this directly

Calls 2

GetButtonFunction · 0.85
SetStateMethod · 0.45

Tested by

no test coverage detected