第二讲准备kodigo的排版服务n_svc_resize

第二讲准备kodigo的排版服务n_svc_resize

讲这个服务前,先介绍一下结构str_resize

global type str_resize from structure

       dragobject             control//待排对象的引用

       string             controlname//对象类名

       integer           sizeorder//排版序(即多个同级排版的先后序)

       boolean          dock//是否按停靠方式

       integer           docktype

//停靠类型:1 向顶靠 2 向左靠 3 向右靠 4 向底靠 5 填充全部

       integer           dockpadtop//向顶预留

       integer           dockpadleft//向左预留

       integer           dockpadright//向右预留

       integer           dockpadbottom//向底预留

       boolean          anchortop//是否向顶瞄定

       boolean          anchorleft//是否向左瞄定

       boolean          anchorright//是否向右瞄定

       boolean          anchorbottom//是否向度瞄定

//(注:除了动态建立的对象,PB的对象名,和类名一般一样)

       string             reftop//顶接对象类名

       string             refleft//左接对象类名

       string             refright//右接对象类名

       string             refbottom//底接对象类名

       rect                bounds//对象边界,实际上就是对象resize前的矩形

       string             ancestor//kodigo级祖先类名(cfbase中有定义)

       integer           reftopindex//顶接对象索引

       integer           refleftindex//左接对象索引

       integer           refrightindex//右接对象索引

       integer           refbottomindex//底接对象索引

       boolean          ignorevisible//虽然不显视,但是否预留空间

end type

 

再注意观查fcmainu打头的对象,是不是每个对象都有:

type variables

Public:

Long #SizeOrder

Boolean #AnchorTop

Boolean #AnchorLeft

Boolean #AnchorRight

Boolean #AnchorBottom

Boolean #Dock

Long #DockType, #DockPadTop, #DockPadLeft, #DockPadRight, #DockPadBottom

String #Dock_Control_Top, #Dock_Control_Left, #Dock_Control_Right, #Dock_Control_Bottom

Boolean #Tooltip

string #TooltipText

Boolean #BalloonTooltip

icon #TooltipIcon = none!

string #TooltipTitle

Private:

str_resize istr_resize

end variables

 

public function str_resize of_getresizeattrib ();istr_resize.Control = this

istr_resize.ControlName = ClassName(this)

istr_resize.SizeOrder = #SizeOrder

istr_resize.SizeOrder = #SizeOrder

istr_resize.Dock = #Dock

istr_resize.DockType = #DockType

istr_resize.DockPadTop = #DockPadTop

istr_resize.DockPadLeft = #DockPadLeft

istr_resize.DockPadRight = #DockPadRight

istr_resize.DockPadBottom = #DockPadBottom

istr_resize.AnchorTop = #AnchorTop

istr_resize.AnchorLeft = #AnchorLeft

istr_resize.AnchorRight = #Anchorright

istr_resize.AnchorBottom = #Anchorbottom

istr_resize.reftop = #Dock_Control_top

istr_resize.refleft = #Dock_Control_left

istr_resize.refright = #Dock_Control_right

istr_resize.refbottom = #Dock_Control_bottom

istr_resize.bounds.left = X

istr_resize.bounds.top = Y

istr_resize.bounds.right = width

istr_resize.bounds.bottom = height

RETURN istr_resize

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值