📄 testpanel.htm
字号:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
<style>
div.panel{
z-index:10000;
width:80px;
height:200px;
top:0;
left:0;
position:absolute;
border:solid 1px #003366;
background:#FFFFFF;
padding-top:20px;
}
div.panelDrag{
z-index:10002;
position:absolute;
top:0px;
left:0px;
width:80px;
height:15px;
background:#3333CC;
border:solid 1px black;
font-size:12px;
color:white;
behavior:url('../htc/sndrag.htc');
}
</style>
</head>
<script>
function setPanelPosition(){
panel1.style.left=event.left;
panel1.style.top=event.top;
}
function setPanelScroll(){
panel1.style.top=parseInt(document.body.scrollTop);
panel1.style.left=parseInt(document.body.scrollLeft);
panelDraghandle.style.top=parseInt(document.body.scrollTop);
panelDraghandle.style.left=parseInt(document.body.scrollLeft);
}
</script>
<body style="margin:0px" onscroll="setPanelScroll()">
<div id="panelDraghandle" class="panelDrag" onDraging="setPanelPosition()" align="center">操作面板</div>
<div id="panel1" class="panel">
<button onClick="beginCreateNode(1);">创建任务</button>
<button onClick="alert('createArray')">创建连线</button>
<hr />
<button onClick="alert('delete selected')">删除所选</button>
<hr />
<button onClick="document.body.scrollTop=20">保存</button>
</div>
<div id=text1 style="position:absolute;top:1000px;left:2000px" >text1</div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -