Update of /cvsroot/pywin32/pywin32/Pythonwin
In directory sc8-pr-cvs1:/tmp/cvs-serv5418
Modified Files:
win32ctrlTree.cpp win32tooltip.cpp
Log Message:
Add PyCTreeCtrl.GetToolTips() and PyCToolTipCtr.SetMaxTipWidth()
Index: win32ctrlTree.cpp
===================================================================
RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32ctrlTree.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** win32ctrlTree.cpp 18 Dec 2002 11:44:00 -0000 1.3
--- win32ctrlTree.cpp 3 Nov 2003 07:35:32 -0000 1.4
***************
*** 708,711 ****
--- 708,721 ----
}
+ // @pymethod <o PyCToolTopCtrl>|PyCTreeCtrl|GetToolTips|Returns the tooltip control
+ PyObject *PyCTreeCtrl_GetToolTips( PyObject *self, PyObject *args )
+ {
+ CTreeCtrl *pList = GetTreeCtrl(self);
+ if (!pList) return NULL;
+ CHECK_NO_ARGS2(args,"GetToolTips");
+ CToolTipCtrl*ret = pList->GetToolTips();
+ return ui_assoc_object::make( PyCToolTipCtrl::type, ret)->GetGoodRet();
+ }
+
// @pymethod (int, int)|PyCTreeCtrl|HitTest|Determines which tree view item, if any, is at a specified position.
PyObject *PyCTreeCtrl_HitTest( PyObject *self, PyObject *args )
***************
*** 761,764 ****
--- 771,775 ----
{"GetDropHilightItem",PyCTreeCtrl_GetDropHilightItem, 1}, // @pymeth GetDropHilightItem|Retrieves the target of a drag-and-drop operation.
{"GetRootItem", PyCTreeCtrl_GetRootItem, 1}, // @pymeth GetRootItem|Retrieves the root of the specified tree view item.
+ {"GetToolTips", PyCTreeCtrl_GetToolTips, 1}, // @pymeth GetToolTips|Returns the tooltip control
{"GetItem", PyCTreeCtrl_GetItem, 1}, // @pymeth GetItem|Retrieves the details of an items attributes.
{"SetItem", PyCTreeCtrl_SetItem, 1}, // @pymeth SetItem|Sets some of all of an items attributes.
Index: win32tooltip.cpp
===================================================================
RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32tooltip.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** win32tooltip.cpp 1 Sep 1999 23:33:02 -0000 1.1
--- win32tooltip.cpp 3 Nov 2003 07:35:32 -0000 1.2
***************
*** 161,164 ****
--- 161,183 ----
+ // @pymethod int|PyCToolTipCtrl|SetMaxTipWidth|
+ static PyObject *
+ PyCToolTipCtrl_set_max_tip_width(PyObject *self, PyObject *args)
+ {
+ int width;
+ if (!PyArg_ParseTuple(args, "i:SetMaxTipWidth",
+ &width)) // @pyparm int|width||The new width
+ return NULL;
+
+ CToolTipCtrl *pTTC = GetToolTipCtrl(self);
+ if (!pTTC)return NULL;
+
+ GUI_BGN_SAVE;
+ int rc = pTTC->SetMaxTipWidth(width);
+ GUI_END_SAVE;
+ return PyInt_FromLong(rc);
+ }
+
+
// @object PyCToolTipCtrl|A windows tooltip control. Encapsulates an MFC <c CToolTipCtrl> class. Derived from <o PyCControl>.
***************
*** 167,170 ****
--- 186,190 ----
{"UpdateTipText", PyCToolTipCtrl_update_tip_text, 1}, // @pymeth UpdateTipText|Update the tool tip text for a control's tools
{"AddTool", PyCToolTipCtrl_add_tool, 1}, // @pymeth AddTool|Adds a tool to tooltip control.
+ {"SetMaxTipWidth", PyCToolTipCtrl_set_max_tip_width, 1}, // @pymeth SetMaxTipWidth|
{NULL, NULL}
};
|