浏览代码

1

样式分支
fyf 2 年前
父节点
当前提交
a3afc5228d
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. +3
    -1
      BeDesignerSCADA/Controls/MenuRunCanvas.xaml.cs

+ 3
- 1
BeDesignerSCADA/Controls/MenuRunCanvas.xaml.cs 查看文件

@@ -89,12 +89,14 @@ namespace BeDesignerSCADA.Controls
/// <param name="canvas"></param>
public void RunMenu(MenuModel canvas)
{
int k = 0;
ItemsPanelTemplate itemsPanelTemplate = new ItemsPanelTemplate();
FrameworkElementFactory _StackPanel = new FrameworkElementFactory(typeof(StackPanel));
switch (canvas.Alignment)
{
case MenuAlignment.左边:
int k = (canvas.Name.Length / 5 -1+ (canvas.Name.Length % 5 > 0 ? 1 : 0))*15;
if(!string.IsNullOrEmpty(canvas.Name))
k = (canvas.Name.Length / 5 -1+ (canvas.Name.Length % 5 > 0 ? 1 : 0))*15;
//左边菜单栏
PageList.HorizontalAlignment = HorizontalAlignment.Stretch;
PageList.VerticalAlignment = VerticalAlignment.Top;


正在加载...
取消
保存