DAVISM@kcgl1.eng.ohio-state.edu (Michael T. Davis) (07/23/89)
I am in the process of writing a new widget which will be a subclass
of the Core widget. I would like to be able to set/get values of certain
instance record values in this new widget's part of the instance record using
the XtSetValues/XtGetValues functions. Am I right in guessing that the fields
in the Core's part of the instance record named intialize_hook, set_values_hook
and get_values_hook pertain to what I'm trying to do? If so (or if not ;-),
could someone please explain how to do this?
Much obliged,
Mike
________________________________________________________________________
| InterNet> davism@{kcgl1.eng|rcgl1.eng|osu-20.ircc}.ohio-state.edu |
| -or- |
| davis-m@eng.ohio-state.edu |
| CompuServe> 73667,541 |
|************************************+***********************************|
| "Daddy, Daddy!! Why's Mommy | |
| running across the field?" | These_Thoughts := My_Own |
| "Just shut up, Son, and reload." | |
------------------------------------------------------------------------kit@EXPO.LCS.MIT.EDU (Chris D. Peterson) (07/26/89)
> I am in the process of writing a new widget which will be a subclass > of the Core widget. I would like to be able to set/get values of certain > instance record values in this new widget's part of the instance record using > the XtSetValues/XtGetValues functions. Am I right in guessing that the fields > in the Core's part of the instance record named intialize_hook, set_values_hook > and get_values_hook pertain to what I'm trying to do? If so (or if not ;-), > could someone please explain how to do this? If you are storing these resources in the instance part of your new widget then you do not need to use the *Hook functions. GetValues() will just return the data stored in the instance structure. SetValues() will pass you a copy of the instance structure before and after the new values have been inserted. Take a look at the Athena Simple Widget and Template widgets for some example source code. Chris D. Peterson MIT X Consortium Net: kit@expo.lcs.mit.edu Phone: (617) 253 - 9608 Address: MIT - Room NE43-213