CorelDRAW VBA插件: 价值上千元的定置插件,批量旋转移动间距镜像等很多功能
蘭雅sRGB ceaa9454f2 蘭雅CorelVBA工具 2024.5.1 永久免费开源开放 lyvba.com | преди 6 месеца | |
---|---|---|
Form | преди 10 месеца | |
img | преди 1 година | |
ALGO.bas | преди 10 месеца | |
API.bas | преди 10 месеца | |
AverageDistance.bas | преди 10 месеца | |
Box.bas | преди 10 месеца | |
LinesForm.frm | преди 6 месеца | |
LinesForm.frx | преди 6 месеца | |
MirrorParalleHorizon.bas | преди 10 месеца | |
README.md | преди 1 година | |
RotateMoveDuplicate.bas | преди 10 месеца | |
ThisMacroStorage.cls | преди 6 месеца | |
Tools.bas | преди 6 месеца | |
lines.bas | преди 10 месеца |
Lanya_LinesTool.zip
GMS下载Public Function Simple_box_one()
ActiveDocument.Unit = cdrMillimeter
l = 100: w = 50: h = 70: b = 15
boxL = 2 * l + 2 * w + b
boxH = h
l1x = w
l2x = w + l
l3x = 2 * w + l
l4x = 2 * (w + l)
Set Rect = ActiveLayer.CreateRectangle(0, 0, boxL, boxH)
Set sl1 = DrawLine(l1x, 0, l1x, h)
Set sl2 = DrawLine(l2x, 0, l2x, h)
Set sl3 = DrawLine(l3x, 0, l3x, h)
Set sl4 = DrawLine(l4x, 0, l4x, h)
End Function
Public Function Simple_box_two()
ActiveDocument.Unit = cdrMillimeter
l = 100: w = 50: h = 70: b = 15
boxL = 2 * l + 2 * w + b: boxH = h
l1x = w: l2x = w + l: l3x = 2 * w + l: l4x = 2 * (w + l)
Set mainRect = ActiveLayer.CreateRectangle(0, 0, boxL, boxH)
Set topRect = ActiveLayer.CreateRectangle(0, 0, l, w)
topRect.Move l1x, h
Set bottomRect = ActiveLayer.CreateRectangle(0, 0, l, w)
bottomRect.Move l3x, -w
Set sl1 = DrawLine(l1x, 0, l1x, h)
Set sl2 = DrawLine(l2x, 0, l2x, h)
Set sl3 = DrawLine(l3x, 0, l3x, h)
Set sl4 = DrawLine(l4x, 0, l4x, h)
End Function
'// 画一条线,设置轮廓色 M100
Private Function DrawLine(X1, Y1, X2, Y2) As Shape
Set DrawLine = ActiveLayer.CreateLineSegment(X1, Y1, X2, Y2)
DrawLine.Outline.SetProperties Color:=CreateCMYKColor(0, 100, 0, 0)
End Function
CreateRectangle(0, 0, l, b, 50, 50)
,第5-6参数,指定上2圆角的系数s
确定范围大小DrawWing(s As Shape)
函数来手工绘制,如图sp.AppendLineSegment 4, y - 2.5
'// 绘制直线sp.AppendCurveSegment2 6.5, y, 4.1, y - 1.25, 5.1, y
'// 绘制曲线https://github.com/hongwenjun/vbabox/blob/main/Box.bas
Private Sub MakeBox_Click()
box.Simple_box_three
End Sub