自定义场地布局修改
This commit is contained in:
@@ -193,21 +193,21 @@ function Pnt.custom_field()
|
||||
|
||||
--Draw page
|
||||
setFont(55)
|
||||
mStr(S.page,100,510)
|
||||
mStr(S.page,100,530)
|
||||
mStr(#FIELD,100,600)
|
||||
gc.rectangle("fill",50,590,100,6)
|
||||
gc.rectangle("fill",50,600,100,6)
|
||||
|
||||
--Draw pen color
|
||||
local pen=S.pen
|
||||
if pen>0 then
|
||||
gc.setLineWidth(13)
|
||||
gc.setColor(SKIN.libColor[pen])
|
||||
gc.rectangle("line",545,495,70,70)
|
||||
gc.rectangle("line",565,495,70,70)
|
||||
elseif pen==-1 then
|
||||
gc.setLineWidth(5)
|
||||
gc.setColor(.9,.9,.9)
|
||||
gc.line(555,505,605,555)
|
||||
gc.line(555,555,605,505)
|
||||
gc.line(575,505,625,555)
|
||||
gc.line(575,555,625,505)
|
||||
end
|
||||
|
||||
--Confirm reset
|
||||
@@ -264,17 +264,18 @@ WIDGET.init("custom_field",{
|
||||
|
||||
WIDGET.newButton({name="any", x=600, y=400,w=120,color="lGrey", font=40,code=setPen(0)}),
|
||||
WIDGET.newButton({name="space", x=730, y=400,w=120,color="grey", font=65,code=setPen(-1)}),
|
||||
WIDGET.newButton({name="copy", x=905, y=400,w=120,color="lRed", font=35,code=WIDGET.lnk.pressKey("cC")}),
|
||||
WIDGET.newButton({name="paste", x=1035, y=400,w=120,color="lBlue", font=35,code=WIDGET.lnk.pressKey("cV")}),
|
||||
WIDGET.newButton({name="clear", x=1165, y=400,w=120,color="white", font=40,code=WIDGET.lnk.pressKey("delete")}),
|
||||
WIDGET.newButton({name="pushLine", x=990, y=400,w=120,h=120,color="lYellow",font=20,code=WIDGET.lnk.pressKey("k")}),
|
||||
WIDGET.newButton({name="delLine", x=1120, y=400,w=120,h=120,color="lYellow",font=20,code=WIDGET.lnk.pressKey("l")}),
|
||||
|
||||
WIDGET.newButton({name="newPage", x=680, y=530,w=90,h=90,color="sky",font=15,code=WIDGET.lnk.pressKey("n")}),
|
||||
WIDGET.newButton({name="delPage", x=780, y=530,w=90,h=90,color="lRed",font=15,code=WIDGET.lnk.pressKey("m")}),
|
||||
WIDGET.newButton({name="prevPage", x=880, y=530,w=90,h=90,color="lGreen",font=15,code=WIDGET.lnk.pressKey("sTab"),hide=WIDGET.lnk.STPeq("page",1)}),
|
||||
WIDGET.newButton({name="nextPage", x=980, y=530,w=90,h=90,color="lGreen",font=15,code=WIDGET.lnk.pressKey("tab"),hide=function()return sceneTemp.page==#FIELD end}),
|
||||
WIDGET.newButton({name="pushLine", x=1080, y=530,w=90,h=90,color="lYellow",font=20,code=WIDGET.lnk.pressKey("k")}),
|
||||
WIDGET.newButton({name="delLine", x=1180, y=530,w=90,h=90,color="lYellow",font=20,code=WIDGET.lnk.pressKey("l")}),
|
||||
WIDGET.newSwitch({name="demo", x=755, y=640, disp=WIDGET.lnk.STPval("demo"),code=WIDGET.lnk.STPrev("demo")}),
|
||||
WIDGET.newButton({name="copy", x=730, y=530,w=120,color="lRed", font=35,code=WIDGET.lnk.pressKey("cC")}),
|
||||
WIDGET.newButton({name="paste", x=860, y=530,w=120,color="lBlue", font=35,code=WIDGET.lnk.pressKey("cV")}),
|
||||
WIDGET.newButton({name="clear", x=990, y=530,w=120,color="white", font=40,code=WIDGET.lnk.pressKey("delete")}),
|
||||
WIDGET.newSwitch({name="demo", x=755, y=640,disp=WIDGET.lnk.STPval("demo"),code=WIDGET.lnk.STPrev("demo")}),
|
||||
|
||||
WIDGET.newButton({name="newPage", x=100, y=110,w=160,h=110,color="sky",font=20,code=WIDGET.lnk.pressKey("n")}),
|
||||
WIDGET.newButton({name="delPage", x=100, y=230,w=160,h=110,color="lRed",font=20,code=WIDGET.lnk.pressKey("m")}),
|
||||
WIDGET.newButton({name="prevPage", x=100, y=350,w=160,h=110,color="lGreen",font=20,code=WIDGET.lnk.pressKey("sTab"),hide=WIDGET.lnk.STPeq("page",1)}),
|
||||
WIDGET.newButton({name="nextPage", x=100, y=470,w=160,h=110,color="lGreen",font=20,code=WIDGET.lnk.pressKey("tab"),hide=function()return sceneTemp.page==#FIELD end}),
|
||||
|
||||
WIDGET.newButton({name="back", x=1140, y=640, w=170,h=80,font=40,code=WIDGET.lnk.BACK}),
|
||||
})
|
||||
Reference in New Issue
Block a user