![]()
![]()
![]()
MUIM_AskMinMax ============== With MUIM_AskMinMax, MUI wants to find out about the minimum, maximum and default sizes of your object. These values are needed for the correct layout, depending on the type of group that contains your object. static ULONG mAskMinMax( struct IClass *cl, Object *obj, struct MUIP_AskMinMax *msg) { /* ** let our superclass first fill in what it thinks about sizes. ** this will e.g. add the size of frame and inner spacing. */ DoSuperMethodA(cl,obj,msg); /* ** now add the values specific to our object. note that we ** indeed need to *add* these values, not just set them! */ /* x-size depending on objects font */ msg->MinMaxInfo->MinWidth += _font(obj)->tf_XSize * 10; msg->MinMaxInfo->DefWidth += _font(obj)->tf_XSize * 20; msg->MinMaxInfo->MaxWidth += MAXMAX; /* unlimited */ /* fixed y-size */ msg->MinMaxInfo->MinHeight += _font(obj)->tf_YSize; msg->MinMaxInfo->DefHeight += _font(obj)->tf_YSize; msg->MinMaxInfo->MaxHeight += _font(obj)->tf_YSize; return(0); }