$PBExportHeader$w_button.srw
forward
global type w_button from window
end type
type cb_11 from commandbutton within w_button
end type
type cb_10 from commandbutton within w_button
end type
type em_3 from editmask within w_button
end type
type em_2 from editmask within w_button
end type
type em_1 from editmask within w_button
end type
type cb_9 from commandbutton within w_button
end type
type cb_8 from commandbutton within w_button
end type
type cb_7 from commandbutton within w_button
end type
type cb_6 from commandbutton within w_button
end type
type cb_5 from commandbutton within w_button
end type
type cb_4 from commandbutton within w_button
end type
type cb_3 from commandbutton within w_button
end type
type cb_2 from commandbutton within w_button
end type
type cb_1 from commandbutton within w_button
end type
type st_1 from statictext within w_button
end type
type ws_position from structure within w_button
end type
end forward
type ws_position from structure
long xpos
long ypos
end type
global type w_button from window
integer width = 2400
integer height = 1800
boolean titlebar = true
string title = "特殊形状数据窗口演示"
boolean controlmenu = true
boolean minbox = true
boolean maxbox = true
long backcolor = 17725690
string icon = "AppIcon!"
boolean center = true
cb_11 cb_11
cb_10 cb_10
em_3 em_3
em_2 em_2
em_1 em_1
cb_9 cb_9
cb_8 cb_8
cb_7 cb_7
cb_6 cb_6
cb_5 cb_5
cb_4 cb_4
cb_3 cb_3
cb_2 cb_2
cb_1 cb_1
st_1 st_1
end type
global w_button w_button
type prototypes
FUNCTION ulong CreateRoundRectRgn(Long x1, Long y1, Long x2, Long y2, Long x3, Long y3) library "gdi32"
FUNCTION ulong CreatePolygonRgn (ref ws_position lppt[], int cPoints, int fnPolyFillMode ) Library "gdi32"
FUNCTION ulong CreateEllipticRgn( Long x1, Long y1, Long x2, Long y2) library "gdi32"
FUNCTION ulong SetWindowRgn(ulong hWnd,ulong hRgn,boolean bRedraw) LIBRARY "user32"
FUNCTION ulong CombineRgn(Long hDestRgn, Long hSrcRgn1, Long hSrcRgn2, Long nCombineMode ) LIBRARY "gdi32"
Function Long SetParent( Long hWndChild, Long hWndNewParent) library "user32"
Subroutine keybd_event(long bVk, long bScan, long dwFlags, long dwExtraInfo) LIBRARY "user32.dll"
end prototypes
forward prototypes
public function integer of_set_oval (commandbutton acb_button)
public function integer wf_set_color ()
end prototypes
public function integer of_set_oval (commandbutton acb_button);//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_x1, ll_x2, ll_x3
long ll_y1, ll_y2, ll_y3
long ll_handle
ll_x1 = 1
ll_y1 = 1
ll_x2 = UnitsToPixels(acb_button.width, xunitstopixels!)
ll_y2 = UnitsToPixels(acb_button.height, yunitstopixels!)
ll_x3 = 64
ll_y3 = 64
ll_handle = CreateRoundRectRgn(ll_x1, ll_y1, ll_x2, ll_y2, ll_x3, ll_y3)
SetwindowRgn(handle(acb_button), ll_handle, true)
return 1
end function
public function integer wf_set_color ();long ll_red, ll_green, ll_blue
long ll_data
ll_red = long(em_1.text)
ll_green = long(em_2.text)
ll_blue = long(em_3.text)
ll_data = rgb(ll_red, ll_green, ll_blue)
this.backcolor = ll_data
em_1.backcolor = ll_data
em_2.backcolor = ll_data
em_3.backcolor = ll_data
st_1.backcolor = ll_data
return 1
end function
on w_button.create
this.cb_11=create cb_11
this.cb_10=create cb_10
this.em_3=create em_3
this.em_2=create em_2
this.em_1=create em_1
this.cb_9=create cb_9
this.cb_8=create cb_8
this.cb_7=create cb_7
this.cb_6=create cb_6
this.cb_5=create cb_5
this.cb_4=create cb_4
this.cb_3=create cb_3
this.cb_2=create cb_2
this.cb_1=create cb_1
this.st_1=create st_1
this.Control[]={this.cb_11,&
this.cb_10,&
this.em_3,&
this.em_2,&
this.em_1,&
this.cb_9,&
this.cb_8,&
this.cb_7,&
this.cb_6,&
this.cb_5,&
this.cb_4,&
this.cb_3,&
this.cb_2,&
this.cb_1,&
this.st_1}
end on
on w_button.destroy
destroy(this.cb_11)
destroy(this.cb_10)
destroy(this.em_3)
destroy(this.em_2)
destroy(this.em_1)
destroy(this.cb_9)
destroy(this.cb_8)
destroy(this.cb_7)
destroy(this.cb_6)
destroy(this.cb_5)
destroy(this.cb_4)
destroy(this.cb_3)
destroy(this.cb_2)
destroy(this.cb_1)
destroy(this.st_1)
end on
event mousemove;Send(handle(this), 274, 61458, 0)
end event
type cb_11 from commandbutton within w_button
integer x = 1216
integer y = 1096
integer width = 562
integer height = 148
integer taborder = 70
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "半圆形花边"
end type
event clicked;//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_handle, ll_data
ws_position lws_pointapi[]
long ll_xpos, ll_ypos, ll_width, ll_height
long ll_xnum, ll_ynum
long ll_x, ll_y, ll_flower = 20
long ll_i, ll_k
ll_xpos = 1
ll_ypos = 1
ll_width = UnitsToPixels(parent.width, xunitstopixels!)
ll_height = UnitsToPixels(parent.height, yunitstopixels!)
ll_xpos = ll_xpos + 5
ll_ypos = ll_ypos + 25 + ll_flower
ll_width = ll_width - 20
ll_width = ll_width - mod(ll_width - ll_xpos, ll_flower)
ll_xnum = (ll_width- ll_xpos) / ll_flower
ll_height = ll_height - 20
ll_height = ll_height - mod(ll_height - ll_ypos, ll_flower)
ll_ynum = (ll_height - ll_ypos) / ll_flower
lws_pointapi[1].xpos = ll_xpos + ll_flower / 2
lws_pointapi[1].ypos = ll_ypos - ll_flower / 2
lws_pointapi[2].xpos = ll_width + ll_flower / 2
lws_pointapi[2].ypos = ll_ypos - ll_flower / 2
lws_pointapi[3].xpos = ll_width + ll_flower / 2
lws_pointapi[3].ypos = ll_height + ll_flower /2
lws_pointapi[4].xpos = ll_xpos + ll_flower - ll_flower / 2
lws_pointapi[4].ypos = ll_height + ll_flower/2
ll_handle = CreatePolygonRgn(lws_pointapi[], 4, 1)
for ll_i = 1 to ll_xnum + 1
ll_y = ll_ypos - ll_flower
ll_x = ll_xpos + ll_flower * ( ll_i - 1 )
ll_data = CreateEllipticRgn(ll_x, ll_y, ll_x + ll_flower, ll_y + ll_flower)
CombineRgn(ll_handle, ll_handle, ll_data, 2)
next
for ll_i = 1 to ll_ynum + 1
ll_y = ll_ypos + ll_flower * ( ll_i - 1 )
ll_x = ll_xpos + ll_flower * ll_xnum
ll_data = CreateEllipticRgn(ll_x, ll_y, ll_x + ll_flower, ll_y + ll_flower)
CombineRgn(ll_handle, ll_handle, ll_data, 2)
next
for ll_i = 1 to ll_xnum + 1
ll_y = ll_ypos + ll_flower * ll_ynum
ll_x = ll_xpos + ll_flower * (ll_xnum - ll_i + 1)
ll_data = CreateEllipticRgn(ll_x, ll_y, ll_x + ll_flower, ll_y + ll_flower)
CombineRgn(ll_handle, ll_handle, ll_data, 2)
next
for ll_i = 1 to ll_ynum + 1
ll_y = ll_ypos + ll_flower * (ll_ynum - ll_i + 1)
ll_x = ll_xpos
ll_data = CreateEllipticRgn(ll_x, ll_y, ll_x + ll_flower, ll_y + ll_flower)
CombineRgn(ll_handle, ll_handle, ll_data, 2)
next
SetwindowRgn(handle(parent), ll_handle, true)
end event
type cb_10 from commandbutton within w_button
integer x = 1216
integer y = 1096
integer width = 562
integer height = 148
integer taborder = 60
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "关闭窗口"
end type
event clicked;close(parent)
end event
type em_3 from editmask within w_button
event editchanged pbm_enchange
integer x = 1289
integer y = 104
integer width = 251
integer height = 92
integer taborder = 60
integer textsize = -9
integer weight = 400
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
long textcolor = 33554432
long backcolor = 17725690
string text = "14"
alignment alignment = right!
borderstyle borderstyle = stylelowered!
string mask = "###"
boolean autoskip = true
boolean spin = true
double increment = 5
string minmax = "0~~255"
end type
event editchanged;wf_set_color()
end event
type em_2 from editmask within w_button
event editchanged pbm_enchange
integer x = 1024
integer y = 104
integer width = 251
integer height = 92
integer taborder = 60
integer textsize = -9
integer weight = 400
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
long textcolor = 33554432
long backcolor = 17725690
string text = "120"
alignment alignment = right!
borderstyle borderstyle = stylelowered!
string mask = "###"
boolean autoskip = true
boolean spin = true
double increment = 5
string minmax = "0~~255"
end type
event editchanged;wf_set_color()
end event
type em_1 from editmask within w_button
event editchanged pbm_enchange
integer x = 759
integer y = 104
integer width = 251
integer height = 92
integer taborder = 60
integer textsize = -9
integer weight = 400
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
long textcolor = 33554432
long backcolor = 17725690
string text = "250"
alignment alignment = right!
borderstyle borderstyle = stylelowered!
string mask = "###"
boolean autoskip = true
boolean spin = true
double increment = 5
string minmax = "0~~255"
end type
event editchanged;wf_set_color()
end event
type cb_9 from commandbutton within w_button
integer x = 590
integer y = 1096
integer width = 562
integer height = 148
integer taborder = 50
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "圆形花边"
end type
event clicked;//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_handle, ll_data
ws_position lws_pointapi[]
long ll_xpos, ll_ypos, ll_width, ll_height
long ll_xnum, ll_ynum
long ll_x, ll_y, ll_flower = 20
long ll_i, ll_k
ll_xpos = 1
ll_ypos = 1
ll_width = UnitsToPixels(parent.width, xunitstopixels!)
ll_height = UnitsToPixels(parent.height, yunitstopixels!)
ll_xpos = ll_xpos + 5
ll_ypos = ll_ypos + 25 + ll_flower
ll_width = ll_width - 20
ll_width = ll_width - mod(ll_width - ll_xpos, ll_flower)
ll_xnum = (ll_width - ll_xpos) / ll_flower
ll_height = ll_height - 20
ll_height = ll_height - mod(ll_height - ll_ypos, ll_flower)
ll_ynum = (ll_height - ll_ypos) / ll_flower
lws_pointapi[1].xpos = ll_xpos + ll_flower
lws_pointapi[1].ypos = ll_ypos
lws_pointapi[2].xpos = ll_width
lws_pointapi[2].ypos = ll_ypos
lws_pointapi[3].xpos = ll_width
lws_pointapi[3].ypos = ll_height
lws_pointapi[4].xpos = ll_xpos + ll_flower
lws_pointapi[4].ypos = ll_height
ll_handle = CreatePolygonRgn(lws_pointapi[], 4, 1)
for ll_i = 1 to ll_xnum + 1
ll_y = ll_ypos - ll_flower
ll_x = ll_xpos + ll_flower * ( ll_i - 1 )
ll_data = CreateEllipticRgn(ll_x, ll_y, ll_x + ll_flower, ll_y + ll_flower)
CombineRgn(ll_handle, ll_handle, ll_data, 2)
next
for ll_i = 1 to ll_ynum + 1
ll_y = ll_ypos + ll_flower * ( ll_i - 1 )
ll_x = ll_xpos + ll_flower * ll_xnum
ll_data = CreateEllipticRgn(ll_x, ll_y, ll_x + ll_flower, ll_y + ll_flower)
CombineRgn(ll_handle, ll_handle, ll_data, 2)
next
for ll_i = 1 to ll_xnum + 1
ll_y = ll_ypos + ll_flower * ll_ynum
ll_x = ll_xpos + ll_flower * (ll_xnum - ll_i + 1)
ll_data = CreateEllipticRgn(ll_x, ll_y, ll_x + ll_flower, ll_y + ll_flower)
CombineRgn(ll_handle, ll_handle, ll_data, 2)
next
for ll_i = 1 to ll_ynum + 1
ll_y = ll_ypos + ll_flower * (ll_ynum - ll_i + 1)
ll_x = ll_xpos
ll_data = CreateEllipticRgn(ll_x, ll_y, ll_x + ll_flower, ll_y + ll_flower)
CombineRgn(ll_handle, ll_handle, ll_data, 2)
next
SetwindowRgn(handle(parent), ll_handle, true)
end event
type cb_8 from commandbutton within w_button
integer x = 1216
integer y = 628
integer width = 562
integer height = 148
integer taborder = 30
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "圆形窗口"
end type
event clicked;//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_x1, ll_x2, ll_x3
long ll_y1, ll_y2, ll_y3
long ll_handle
long ll_data
ll_data = UnitsToPixels(parent.width, xunitstopixels!)
ll_data = PixelsToUnits(ll_data, ypixelstounits!)
parent.height = ll_data
ll_x1 = 10
ll_y1 = 25
ll_x2 = UnitsToPixels(parent.width, xunitstopixels!) - 10
ll_y2 = UnitsToPixels(parent.height, yunitstopixels!) - 10
ll_handle = CreateEllipticRgn(ll_x1, ll_y1, ll_x2, ll_y2)
SetwindowRgn(handle(parent), ll_handle, true)
return 1
end event
type cb_7 from commandbutton within w_button
integer x = 585
integer y = 940
integer width = 562
integer height = 148
integer taborder = 40
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "波浪花边"
end type
event clicked;long ll_xpos, ll_ypos, ll_width, ll_height
long ll_x, ll_y, ll_flower = 80
long ll_i, ll_k, ll_max = 40, ll_min = 35
long ll_handle
ws_position lws_pointapi[]
ll_xpos = 1
ll_ypos = 1
ll_width = UnitsToPixels(parent.width, xunitstopixels!)
ll_height = UnitsToPixels(parent.height, yunitstopixels!)
ll_k = 1
for ll_i = 1 to ll_flower
if mod(ll_i, 2) = 0 then
ll_y = ll_ypos + ll_max
else
ll_y = ll_ypos + ll_min
end if
ll_x = ll_xpos + ll_width / ll_flower * ll_i
lws_pointapi[ll_k].xpos = ll_x
lws_pointapi[ll_k].ypos = ll_y
ll_k ++
next
for ll_i = 1 to ll_flower
if mod(ll_i, 2) = 0 then
ll_x = ll_width - 5
else
ll_x = ll_width - ll_max + ll_min - 5
end if
ll_y = ll_ypos + ll_height / ll_flower * ll_i + ll_min
lws_pointapi[ll_k].xpos = ll_x
lws_pointapi[ll_k].ypos = ll_y
ll_k ++
next
for ll_i = 1 to ll_flower
if mod(ll_i, 2) = 1 then
ll_y = ll_height - 5
else
ll_y = ll_height - ll_max + ll_min - 5
end if
ll_x = ll_width - ll_width / ll_flower * ll_i - 5
lws_pointapi[ll_k].xpos = ll_x
lws_pointapi[ll_k].ypos = ll_y
ll_k ++
next
for ll_i = 1 to ll_flower
if mod(ll_i, 2) = 1 then
ll_x = ll_xpos + 5
else
ll_x = ll_xpos + ll_max - ll_min + 5
end if
ll_y = ll_height - ll_height / ll_flower * ll_i + ll_min
lws_pointapi[ll_k].xpos = ll_x
lws_pointapi[ll_k].ypos = ll_y
ll_k ++
next
ll_handle = CreatePolygonRgn(lws_pointapi[], upperbound(lws_pointapi), 1)
//其中第 1 个参数为多边形各个顶点坐标值的数组
//其中第 2 个参数为多边形边数,可修改,配合数组值
//其中第 3 个参数为填充模式 ALTERNATE /WINDING
SetwindowRgn(handle(parent), ll_handle, true)
end event
type cb_6 from commandbutton within w_button
integer x = 585
integer y = 784
integer width = 562
integer height = 148
integer taborder = 30
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "八边形窗口"
end type
event clicked;//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_handle
ws_position lws_pointapi[]
// 图形2
int li_xpos, li_ypos, li_width, li_height
li_xpos = 12
li_ypos = 1
li_width = UnitsToPixels(parent.width, xunitstopixels!) - 32
li_height = UnitsToPixels(parent.height, yunitstopixels!) - 32
lws_pointapi[1].xpos = li_xpos
lws_pointapi[1].ypos = li_ypos + li_height / 3
lws_pointapi[2].xpos = li_xpos + li_width / 3
lws_pointapi[2].ypos = li_ypos
lws_pointapi[3].xpos = li_xpos + li_width * 2 / 3
lws_pointapi[3].ypos = li_ypos
lws_pointapi[4].xpos = li_xpos + li_width
lws_pointapi[4].ypos = li_ypos + li_height / 3
lws_pointapi[5].xpos = li_xpos + li_width
lws_pointapi[5].ypos = li_ypos + li_height * 2 / 3
lws_pointapi[6].xpos = li_xpos + li_width * 2 / 3
lws_pointapi[6].ypos = li_ypos + li_height
lws_pointapi[7].xpos = li_xpos + li_width / 3
lws_pointapi[7].ypos = li_ypos + li_height
lws_pointapi[8].xpos = li_xpos
lws_pointapi[8].ypos = li_ypos + li_height * 2 / 3
ll_handle = CreatePolygonRgn(lws_pointapi[], 8, 1)
//其中第 1 个参数为多边形各个顶点坐标值的数组
//其中第 2 个参数为多边形边数,可修改,配合数组值
//其中第 3 个参数为填充模式 ALTERNATE /WINDING
SetwindowRgn(handle(parent), ll_handle, true)
return 1
end event
type cb_5 from commandbutton within w_button
integer x = 1216
integer y = 940
integer width = 562
integer height = 148
integer taborder = 20
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "还原窗口"
end type
event clicked;//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_handle
ws_position lws_pointapi[]
// 图形2
int li_xpos, li_ypos, li_width, li_height
li_xpos = 1
li_ypos = 1
li_width = UnitsToPixels(parent.width, xunitstopixels!)
li_height = UnitsToPixels(parent.height, yunitstopixels!)
lws_pointapi[1].xpos = li_xpos
lws_pointapi[1].ypos = li_ypos
lws_pointapi[2].xpos = li_xpos + li_width
lws_pointapi[2].ypos = li_ypos
lws_pointapi[3].xpos = li_xpos + li_width
lws_pointapi[3].ypos = li_ypos + li_height
lws_pointapi[4].xpos = li_xpos
lws_pointapi[4].ypos = li_ypos + li_height
ll_handle = CreatePolygonRgn(lws_pointapi[], 4, 1)
//其中第 1 个参数为多边形各个顶点坐标值的数组
//其中第 2 个参数为多边形边数,可修改,配合数组值
//其中第 3 个参数为填充模式 ALTERNATE /WINDING
SetwindowRgn(handle(parent), ll_handle, true)
return 1
end event
type cb_4 from commandbutton within w_button
integer x = 585
integer y = 628
integer width = 562
integer height = 148
integer taborder = 30
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "椭圆形窗口"
end type
event clicked;//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_x1, ll_x2, ll_x3
long ll_y1, ll_y2, ll_y3
long ll_handle
parent.width = 2400
parent.height = 1800
ll_x1 = 10
ll_y1 = 25
ll_x2 = UnitsToPixels(parent.width, xunitstopixels!) - 10
ll_y2 = UnitsToPixels(parent.height, yunitstopixels!) - 10
ll_handle = CreateEllipticRgn(ll_x1, ll_y1, ll_x2, ll_y2)
SetwindowRgn(handle(parent), ll_handle, true)
return 1
end event
type cb_3 from commandbutton within w_button
integer x = 1216
integer y = 472
integer width = 562
integer height = 148
integer taborder = 20
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "菱形窗口"
end type
event clicked;//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_handle
ws_position lws_pointapi[]
// 图形2
int li_xpos, li_ypos, li_width, li_height
li_xpos = 1
li_ypos = 1
li_width = UnitsToPixels(parent.width, xunitstopixels!)
li_height = UnitsToPixels(parent.height, yunitstopixels!)
lws_pointapi[1].xpos = li_xpos
lws_pointapi[1].ypos = li_ypos + li_height / 2
lws_pointapi[2].xpos = li_xpos + li_width / 2
lws_pointapi[2].ypos = li_ypos
lws_pointapi[3].xpos = li_xpos + li_width
lws_pointapi[3].ypos = li_ypos + li_height / 2
lws_pointapi[4].xpos = li_xpos + li_width / 2
lws_pointapi[4].ypos = li_ypos + li_height
ll_handle = CreatePolygonRgn(lws_pointapi[], 4, 1)
//其中第 1 个参数为多边形各个顶点坐标值的数组
//其中第 2 个参数为多边形边数,可修改,配合数组值
//其中第 3 个参数为填充模式 ALTERNATE /WINDING
SetwindowRgn(handle(parent), ll_handle, true)
return 1
end event
type cb_2 from commandbutton within w_button
integer x = 585
integer y = 472
integer width = 562
integer height = 148
integer taborder = 20
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "圆角矩形按钮"
end type
event clicked;this.enabled = false
of_set_oval(this)
end event
type cb_1 from commandbutton within w_button
integer x = 1216
integer y = 784
integer width = 562
integer height = 148
integer taborder = 10
integer textsize = -12
integer weight = 700
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
string text = "圆角矩形窗口"
end type
event clicked;//////////////////////////////////////////////////
// //
// 测试用数据(窗口多边形) //
// //
//////////////////////////////////////////////////
long ll_x1, ll_x2, ll_x3
long ll_y1, ll_y2, ll_y3
long ll_handle
ll_x1 = 4
ll_y1 = 4
ll_x2 = UnitsToPixels(parent.width, xunitstopixels!) - 4
ll_y2 = UnitsToPixels(parent.height, yunitstopixels!) - 4
ll_x3 = 250
ll_y3 = 250
ll_handle = CreateRoundRectRgn(ll_x1, ll_y1, ll_x2, ll_y2, ll_x3, ll_y3)
SetwindowRgn(handle(parent), ll_handle, true)
return 1
end event
type st_1 from statictext within w_button
integer x = 567
integer y = 200
integer width = 1207
integer height = 264
boolean bringtotop = true
integer textsize = -8
integer weight = 400
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable
!
string facename = "宋体"
long textcolor = 33554432
long backcolor = 17725690
alignment alignment = center!
boolean focusrectangle = false
end type
event clicked;if this.width <= 1000 then
this.resize(1586, 2164)
else
this.resize(986, 264)
end if
end event
相关推荐
PB与SQL Server 2000打造学生管理信息系统
本文还有配套的精品资源,点击获取 简介:PB学生管理信息系统是一个使用PowerBuilder和SQL Server 2000开发的教育管理应用程序,旨在优化学校对学生的管理。通过这个系统,初学者可以学习如何使用PowerBuilder开发界面和数据库集成,并通过SQL Server 2000进行数据管理。系统的多个模块,包括学生信息、成绩、出勤、课程、教师和权限管理,为数...
PB编程笔记(二)
关键字:PB 为mid!/midhelp!窗口添加背景图片 现有窗口w_main, 要为其添加背景图片,步骤如下: 1. 新建一个窗口,起名为:w_background 2. WindowType属性选:child! 3. 在w_background的open事件里添加如下代码: this.bringtotop=false //该窗口放置在最后后面 this....
普通控件和数据窗口的tooltip示例pb9
在普通控件和数据窗口中实现tooltip示例,版本pb9
[PB]-数据窗口技术
[PB]-数据窗口其他 2011-12-30 11:33 //////////////////////////////// 标识当前行 〓标识当前行也就是给当前行加上醒目的标记,以便用户更清楚当前要对哪一行数据进行操作,尤其当用户的操作中间有停顿时,继续进行操作就特别需要知道哪个是当前行。这里的当前行不要狭隘地理解成仅仅是光标所在行。当翻页时如果光标所在行不在当前页中,
pb12.5下的界面漂亮的图片按钮
经测试可以再pb12.5下稳定运行!界面漂亮
Python量化投资入门教程:从零构建你的第一个交易策略
量化投资教程以数学模型和计算机程序实现超额收益,选用Python工具链完成数据获取、策略构建及回测。通过移动平均线交叉策略示例,展示数据预处理、信号生成、收益计算及可视化全流程,结合收益率、最大回撤和夏普比率评估策略,并建议参数优化与策略融合提升稳健性。
如何在PB中制作特殊形状数据窗口或按钮
如何在PB中制作特殊形状数据窗口或按钮作者:LZP_LRP 责任编辑:LZP_LRP 以下是全部源码,感兴趣的朋友可以整个窗口的源代码导入到PBL里自己运行一下试试。 $PBExportHeader$w_button.srwforwardglobal type w_button from windowend typetype cb_11 from comma
树莓派与stm32通信超详细解答过程
笔者之前发过关于stm32与openmv通信的教程,在学习了几天opencv后,想实现树莓派4B与stm32进行通信。于是上网查询资料,最后实现了两者之间的通信,相信这对大多数电赛人都很有帮助,opencv的识别效果是远高于openmv以及K210的。在此我参考了以下资料辅助我学习,大家可以参考。基于树莓派4B与STM32的UART串口通信实验(代码开源)_树莓派4b串口波特率-CSDN博客。
如何在PB中制作特殊形状数据窗口或按钮介绍
在 CSDN 上,经常有朋友问到不规则窗口或者不规则的按钮如何制作,在这里我介绍 几个比较常用的 API 函数,来实现不规则窗口或者不规则按钮的制作。 一、先看一下效果: 点击一下圆形花边按钮,效果如下: (蓝色的为桌面) CSDN 社区电子杂志—POWERBUILDER 杂志创刊号 二、下面我介绍一下程序中主要用到的几个 API 函数: 1. 创建一个圆角矩形 CreateR
从入门到精通:MediaGo跨平台部署全攻略,Docker+NAS实战案例深度拆解!
本篇将深入解析开源媒体处理工具MediaGo的运作机制,该软件具备跨平台兼容性,支持Windows、MacOS及Linux三大主流操作系统。其核心创新在于采用模块化架构设计,用户无需额外依赖任何插件即可完成快速部署。作为GitHub平台上的开源项目,该工具特别注重用户体验设计,通过Docker容器化方案可无缝接入各类网络存储设备,显著优化系统资源占用并提升数据处理效率。以飞牛云NAS系统为实施案例,本文将详细展示本地化部署全流程。
前端Three.js面试题及参考答案
渲染循环(Render Loop)是 Three.js 中一个非常重要的概念,它是一个不断重复执行的过程,用于更新和渲染 3D 场景。在每次循环中,渲染循环会更新场景中的对象状态,如位置、旋转、缩放等,然后使用渲染器将更新后的场景渲染成 2D 图像显示在屏幕上。通过不断地重复这个过程,就可以实现动画效果。渲染循环的核心作用是确保场景能够实时更新,给用户带来流畅的视觉体验。如果没有渲染循环,场景将是静态的,不会有任何变化。只有通过不断地更新和渲染,才能让场景中的对象动起来,实现各种动画效果。
PB案例学习笔记-19制作一个图片按钮
这是PB案例学习笔记系列文章的第19篇,该系列文章适合具有一定PB基础的读者。通过一个个由浅入深的编程实战案例学习,提高编程技巧,以保证小伙伴们能应付公司的各种开发需求。
PB窗口基础
[PB]-窗口基础 window对象 【其他】 ■窗口画板的定制:Design-Options ■窗口类型:Main(可以使用菜单)、Child(不能使用菜单)、Response(如messagebox函数弹出的窗口,继续执行程序之前必须对其做出响应;不能使用菜单)、Popup(可以使用菜单)、MDI(必须有菜单)、DIHelp(必须有菜单) 【属性】 代码中修改属性:窗口名称
Python 爬虫进阶:爬取 APP 数据(Charles 抓包 + Requests)
本文详细介绍了APP数据爬取的完整技术方案。首先通过Charles抓包工具配置HTTPS代理和证书,解析APP通信协议;然后分析请求参数、反爬机制和动态签名生成规则;接着使用Python的Requests库实现模拟请求、分页爬取和数据存储;最后针对证书问题、Token失效等常见问题提供解决方案。文章强调抓包分析、参数逆向和请求模拟三大核心技术,同时提醒开发者需遵守法律法规,合理控制爬取频率。该方案适用于移动端数据采集场景,为无法直接获取网页数据的情况提供了有效解决方案。
YOLOv11改进策略【模型轻量化】| 替换骨干网络 CVPR-2023 FasterNet 高效快速的部分卷积块
本文记录的是基于FasterNet的YOLOv11轻量化改进方法研究。FasterNet的网络结构借鉴 CNN 的设计理念,通过提出的PConv减少推理时的计算和内存成本,同时减少通道数并增加部分比例,降低延迟,并通过后续的PWConv来弥补特征信息可能缺失的问题,提高了准确性。本文在替换骨干网络中配置了原论文中的和六种模型,以满足不同的需求。
PB 不规则窗体或按钮
源码下载地址: https://download.csdn.net/download/lzp_lrp/10736390 在 CSDN 上,经常有朋友问到不规则窗口或者不规则的按钮如何制作,在这里我介绍 几个比较常用的 API 函数,来实现不规则窗口或者不规则按钮的制作。 一、先看一下效果: 点击一下圆形花边按钮,效果如下: (蓝色的为桌面) CSDN 社区电子杂志—POWERBUILDER 杂...
【C语言】一文搞懂C语言文件操作
读写文件、文件相关库函数详解、文件缓冲区介绍
AltiumDesigner特殊形状pcb绘制教程
通过导入dwg和dxf文件创建复杂pcb形状 作者:tianxin 一个热爱技术的少年 在电路板设计的时候,很多情况设计的电路板并不是规则的,因为大部分情况下设计的电路板形状是根据产品的装配结构设计的,所以在设计电路板设计的时候需要设计出很多不同形状的电路板来,然而对于复杂的电路板形状的设计,在AltiumDesigner软件中是很难实现的,
OV9734 DATASHEET,完整规格书
OV9734完整规格书,包括电气参数,尺寸规格,寄存器配置表等
ssm框架搭建
这个是一个在idea上成功跑起来的ssm框架项目,保存在这里方便以后使用直接下载
制作自定义背景Button按钮、自定义形状Button的全攻略
http://wxmijl.blog.163.com/blog/static/13245928201121942629888/ 如何被推荐? 在Android开发应用中,默认的Button是由系统渲染和管理大小的。而我们看到的成功的移动应用,都是有着酷炫的外观和使用体验的。因此,我们在开发产品的时候,需要对默认按钮进行美化。在本篇里,笔者结合在应用开发中的经验,探讨一下自定义背景的
文档:亲测可用解决vnc灰屏,黑屏,鼠标大黑叉情况
主要解决vnc-viewer灰屏,黑屏,鼠标大黑叉等现象,详细见文档。
pb获取已打开的窗口_在线素材获取好工具,各种素材免费获取
经常制作PPT的用户都知道,在制作一份完整的PPT时,经常会用到很多素材,如模板、图片、文字、形状等,那么这些素材我们从哪获取呢?今天就给大家分享一个非常实用的PPT工具,可以免费获取很多在线素材,已满足我们制作PPT的需要。"PPT 美化大师"是一款美化软件, 它支持 Office 软件。如果计算机正常连接网络, 那么制作 PPT时, 可以直接获取需要的在线素材,包括专业模板、 精美图示、 创意...
pscad IEEE标准系统搭建说明
pscad IEEE标准系统搭建说明,包含典型的IEEE 9节点、14节点、30节点、39节点和118节点系统。内含标准测试系统的原始数据和潮流结果。
pb 如何隐藏数据窗口的图片列_excel处理数据的流程
数据分析基本步骤:明确问题-理解数据-数据清洗-数据分析或构建模型-数据可视化(一)明确问题只有先知道自己需要解决什么问题,后续的数据分析才有意义;理解自己收集来的数据有什么含义,分别代表什么,这有利于后续分析数据背后的意义。(二)理解数据-excel操作自动换行:多行显示超长文本,以便看到单元格的所有内容。显示单元格格式:任意单元格上单击鼠标右键,点击“设置单元格格式”,会弹出窗口展示目前所在列...
【Substance】Substance Painter基本制作流程
目录准备工作使用fill layer完成70%手绘材质完成剩余30% 这篇东西主要来自于官网Substance Painter入门视频教程的要点总结,记录sp中基本概念和制作流程。 中文版链接(中文视频是优酷的不用翻墙) 准备工作 创建项目&导入模型 File → New打开New Project窗口,Select选择要导入的模型。 Normal map format : 法线标准,D...
1300




被折叠的 条评论
为什么被折叠?



