protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); EditorControl editor = new EditorControl(); var viewModel = new EditorViewModel(); editor.DataContext = viewModel; editor.Show(); }
public FindBar(ToolStripContainer workspace, EditorControl editor) { this.editor = editor; var cancelImage = Image.FromFile("/res/critical.png".AsAbsolute()); var goImage = Image.FromFile("/res/findnexths.png".AsAbsolute()); workspace.BottomToolStripPanel.Controls.Add(this); Visible = false; Left = workspace.LeftToolStripPanel.Width; Items.Add("", cancelImage, (_, e) => Visible = false); Items.Add(new ToolStripLabel("Find What:")); ec = new FindBarTextBox() { Width = 300 }; ec.Dismissed += () => { Hide(); editor.Focus(); }; ec.Accepted += () => { DoFind(); }; var i = new ToolStripControlHost(ec) { AutoSize = false, Width = ec.Width }; Items.Add(i); Items.Add(new ToolStripButton("", goImage, (_, e) => DoFind())); RegExCheckBox = new CheckBox() { Text = "Regular Expression", AutoSize = false, Width = 130, Checked = false, BackColor = Color.Transparent, }; CaseSensitivityCheckBox = new CheckBox() { Text = "Case Sensitive", Checked = false, BackColor = Color.Transparent, }; var RegExHost = new ToolStripControlHost(RegExCheckBox) { AutoSize = false, Width = RegExCheckBox.Width }; var CaseHost = new ToolStripControlHost(CaseSensitivityCheckBox) { AutoSize = false, Width = CaseSensitivityCheckBox.Width }; Items.Add(RegExHost); Items.Add(CaseHost); }
public PosTile(EditorControl editor) : base(TileAlignment.Left) { this.editor = editor; }
static void OnSpeListScroll(EditorControl c, Vector2 scrollPos) { //联动时间线视口 GetTimeLineViewCtrl().ScrollPos = scrollPos; }
static void OnPlayCtrlStop(EditorControl c) { }
static void OnPreviewModelValueChanged(EditorControl c, object value) { SpecialEffectAnimClipEditorModel.GetInstance().SetPreviewModel(value as UnityEngine.Object); }
static void OnSaveBtnClick(EditorControl c) { SpecialEffectAnimClipEditorModel.GetInstance().SaveClip(); }
public void Destroy(EditorControl root) { root.Traverse(destroyVisitor); }
public void Focus() { EditorControl.Focus(); }
public virtual void AfterVisitChild(EditorControl c, int ichild) { }
public virtual bool PreVisitChild(EditorControl c, int ichild) { return(true); }
public virtual void AfterVisitChildren(EditorControl c) { }
public virtual bool PreVisitChildren(EditorControl c) { return(true); }
public virtual void AfterVisit(EditorControl c) { }
//Add by liteng for MoveAtlas At 2014/1/4 Start private void VisitByListView(EditorControl c) { ListViewCtrl list = c as ListViewCtrl; if (list == null) { return; } EditorGUI.BeginDisabledGroup(!list.Enable); EditorGUILayout.BeginHorizontal(); EditorGUILayout.BeginVertical(c.GetStyle(), c.GetOptions()); Vector2 newScrollPos = EditorGUILayout.BeginScrollView(list.ScrollPos, false, true, GUIStyle.none, GUI.skin.verticalScrollbar, GUIStyle.none); if (!newScrollPos.Equals(list.ScrollPos)) { c.frameTriggerInfo.isScroll = true; c.frameTriggerInfo.scrollPos = newScrollPos; } list.ScrollPos = newScrollPos; int count = 0; foreach (var item in list.Items) { foreach (var index in list.SelectItems) { if (index == count) { GUI.color = item.onSelectColor; GUI.Box(list.Items[index].lastRect, GUIContent.none); GUI.color = Color.white; break; } } //Modify by liteng for MoveAtlas End GUIContent itemContent = new GUIContent(); itemContent.text = item.name; if (item.image != null) { itemContent.image = item.image; } //add by liteng for atlas begin if (!string.IsNullOrEmpty(item.tooltip)) { itemContent.tooltip = item.tooltip; } //add by liteng end EditorGUILayout.BeginHorizontal(); EditorGUILayout.LabelField(itemContent, itemStyle, new GUILayoutOption[] { GUILayout.MaxWidth(list.LastRect.width - scrollBarWidth) }); SpecialEffectEditorUtility.GetLastRect(ref item.lastRect); EditorGUILayout.EndHorizontal(); //Modify by liteng for MoveAtlas At 2015/1/4 HandleMouseAction(list, count); count++; } HandleDragAction(list); EditorGUILayout.EndScrollView(); EditorGUILayout.EndVertical(); //为了顶住右侧边框,使ScrollView显示完全 //GUILayout.Space(10f); EditorGUILayout.EndHorizontal(); EditorGUI.EndDisabledGroup(); c.UpdateLastRect(); CheckInputEvent(c); }
public void AddExpressionToEditor(EditorControl editor) { editor.Document.MarkerStrategy.AddMarker(begin); editor.Document.MarkerStrategy.AddMarker(expression); editor.Document.MarkerStrategy.AddMarker(end); }
// Use this for initialization void Start() { // Get references to other scripts and objects gameControl = GameObject.Find ("Game").GetComponent<GameControl>(); editorControl = GameObject.Find ("Editor").GetComponent<EditorControl>(); // Initialize the settings file path settingsFilePath = Application.dataPath; if (Application.platform == RuntimePlatform.OSXPlayer) { settingsFilePath += "/../.."; } else if (Application.platform == RuntimePlatform.WindowsPlayer) { settingsFilePath += "/.."; } settingsFilePath += "/settings.txt"; // Init the cameras editorCamera = GameObject.Find("EditorCamera").GetComponent<Camera>(); gameCamera = GameObject.Find("GameCamera").GetComponent<Camera>(); renderTextureCamera = GameObject.Find("RenderTextureCamera").GetComponent<Camera>(); InitCameras(); }
public void RemoveExpressionFromEditor(EditorControl editor) { editor.Document.MarkerStrategy.RemoveMarker(begin); editor.Document.MarkerStrategy.RemoveMarker(expression); editor.Document.MarkerStrategy.RemoveMarker(end); }
//在OnGUI中调用 public void Render(EditorControl root, Rect wndRect) { //Debug.Log("Redner中进入的?:"+root.Caption); //判断上一帧渲染是否被中断 if (isLastRenderVisitorInterrupt) {//如果是 //手动结束上一帧Render,正常执行本帧的Render isLastFrameRendering = false; } //判断上一帧的Render是否在执行中,如果是则不处理 if (isLastFrameRendering) {//如果是 //将窗口置灰,屏蔽所有用户操作 //root.SetEnable(false); return; } else { //root.SetEnable(root.Root.Enable); } isLastFrameRendering = true; if (repaint) { repaint = false; } layoutCalcVisitor.areaStack.Clear(); layoutCalcVisitor.areaStack.Push(wndRect); //计算布局 root.Traverse(layoutCalcVisitor); isLastRenderVisitorInterrupt = true; //渲染控件树 //Debug.Log("root" + root.GetType().ToString()); root.Traverse(renderVisitor); isLastRenderVisitorInterrupt = false; //if(root.Enable) //{ triggerVisitor.Clear(); //收集本帧需要被触发的控件 root.Traverse(triggerVisitor); //集中触发需要触发的控件 foreach (var c in triggerVisitor.triggerControls) { this.Trigger(c); } //清除控件节点中本帧记录的操作 root.Traverse(resetTriggerInfoVisitor); isLastFrameRendering = false; // } }
//----------------------------------------------------------------------------- // Constructors //----------------------------------------------------------------------------- public ScriptEditor(Script script, EditorControl editorControl) { InitializeComponent(); this.script = script; this.editorControl = editorControl; this.previousName = script.Name; this.previousCode = script.Code; this.autoCompile = true; this.compileOnClose = true; this.needsRecompiling = false; this.compileTask = null; if (script.HasErrors) { displayedError = script.Errors[0]; labelErrorMessage.Text = displayedError.ToString(); labelErrorMessage.Image = ZeldaEditor.ResourceProperties.Resources.exclamation; } else { displayedError = null; labelErrorMessage.Text = ""; labelErrorMessage.Image = null; } // Set some UI text. base.Text = "Script Editor: " + script.Name; textBoxName.Text = script.Name; // Create the code editor text box. codeEditor = new FastColoredTextBox(); panelCode.Controls.Add(codeEditor); codeEditor.Dock = DockStyle.Fill; codeEditor.Language = Language.CSharp; codeEditor.Text = script.Code; codeEditor.ReservedCountOfLineNumberChars = 4; codeEditor.IsChanged = false; codeEditor.ClearUndo(); codeEditor.TextChanged += codeEditor_TextChanged; codeEditor.SelectionChanged += codeEditor_SelectionChanged; codeEditor.UndoRedoStateChanged += UpdateUndoRedoButtonStates; // Create the auto-complete menu. autoCompleteMenu = new AutocompleteMenu(codeEditor); autoCompleteMenu.ForeColor = Color.Black; autoCompleteMenu.BackColor = Color.White; autoCompleteMenu.SelectedColor = Color.Orange; autoCompleteMenu.SearchPattern = @"[\w\.]"; autoCompleteMenu.AllowTabKey = true; autoCompleteMenu.Items.SetAutocompleteItems(new DynamicCollection(autoCompleteMenu, script, codeEditor)); // Start a timer to auto-compile the script every 2 seconds. if (autoCompile) { /* * timer = new System.Timers.Timer(2000); * timer.AutoReset = true; * timer.Elapsed += delegate(object sender, System.Timers.ElapsedEventArgs e) { * * //if (needsRecompiling && compileTask == null) { * if (needsRecompiling && !editorControl.IsBusyCompiling) { * //BeginCompilingScript(); * editorControl.CompileScript(script, OnCompileComplete); * editorControl.NeedsRecompiling = true; * } * }; * timer.Start(); */ // Add an idle method to check for compile task completion. Application.Idle += RecompileUpdate; } // Setup the initial undo/redo button states. UpdateUndoRedoButtonStates(this, EventArgs.Empty); }
private void Trigger(EditorControl c) { if (c.frameTriggerInfo.isCtrlBehaveChange) { if (null != c.onCtrlBehaveChange) { c.onCtrlBehaveChange(c); } } if (c.frameTriggerInfo.isClick) { if (null != c.onClick) { c.onClick(c); } } if (c.frameTriggerInfo.isHover) { if (null != c.onHover) { c.onHover(c); } } if (c.frameTriggerInfo.isValueChanged) { if (null != c.onValueChange) { c.onValueChange(c, c.CurrValue); } } if (c.frameTriggerInfo.lastSelectItem != -1) { if (null != c.onItemSelected) { c.onItemSelected(c, c.frameTriggerInfo.lastSelectItem); } } //add by liteng for atlas start if (c.frameTriggerInfo.lastSelectItemR != -1) { if (null != c.onItemSelectedR) { c.onItemSelectedR(c, c.frameTriggerInfo.lastSelectItemR); } } if (c.frameTriggerInfo.lastSelectItemRU != -1) { if (null != c.onItemSelectedRU) { c.onItemSelectedRU(c, c.frameTriggerInfo.lastSelectItemRU); } } //add by liteng end if (c.frameTriggerInfo.isScroll) { if (null != c.onScroll) { c.onScroll(c, c.frameTriggerInfo.scrollPos); } } if (c.frameTriggerInfo.isDraggingObjs) { if (null != c.onDragingObjs) { c.onDragingObjs(c, FrameInputInfo.GetInstance().dragObjs, FrameInputInfo.GetInstance().dragObjsPaths); } } if (c.frameTriggerInfo.isDropObjs) { if (null != c.onDropObjs) { c.onDropObjs(c, FrameInputInfo.GetInstance().dragObjs, FrameInputInfo.GetInstance().dragObjsPaths); } } //Add by liteng for MoveAtlas At 2014/1/4 Start if (c.frameTriggerInfo.isCustomDragAccept) { if (null != c.onAcceptCustomDrag) { c.onAcceptCustomDrag(c, c.DragObject); } } if (c.frameTriggerInfo.isCustomDragAcceptCtrl) { if (null != c.onAcceptCustomDragCtrl) { c.onAcceptCustomDragCtrl(c, c.DragObject); } } if (c.frameTriggerInfo.isCtrlSelectItem) { if (null != c.onItemCtrlSelected) { c.onItemCtrlSelected(c, c.frameTriggerInfo.lastCtrlSelectItem); } } if (c.frameTriggerInfo.isDoubleClick) { if (null != c.onDoubleClick) { c.onDoubleClick(c, c.ClickObject); } } if (c.frameTriggerInfo.isOnPress) { if (null != c.onOnPress) { c.onOnPress(c, c.ClickObject); } } if (c.frameTriggerInfo.isPressDown) { if (null != c.onPressDown) { c.onPressDown(c, c.ClickObject); } } if (c.frameTriggerInfo.isPressUp) { if (null != c.onPressUp) { c.onPressUp(c, c.ClickObject); } } if (c.frameTriggerInfo.isRPressDown) { if (null != c.onRPressDown) { c.onRPressDown(c, c.ClickObject); } } if (c.frameTriggerInfo.isRPressUP) { if (null != c.onRPressUp) { c.onRPressUp(c, c.ClickObject); } } if (c.frameTriggerInfo.isPlay) { if (null != c.onPlay) { c.onPlay(c); } } if (c.frameTriggerInfo.isPause) { if (null != c.onPause) { c.onPause(c); } } if (c.frameTriggerInfo.isStop) { if (null != c.onStop) { c.onStop(c); } } }
/// <summary> /// Initializes a new instance of the <see cref="NewFileCommand"/> class. /// </summary> /// <param name="control">The control.</param> public NewFileCommand(EditorControl control) : base(control) { }
static void OnRedoBtnClick(EditorControl c) { SpecialEffectAnimClipEditorModel.GetInstance().Redo(); }
public void ClearMarkers(EditorControl editor) { editor.Document.MarkerStrategy.RemoveAll(FindQuickMarkers); list.Clear(); editor.Refresh(); }
static void OnDeathTypeComboBoxValueChange(EditorControl c, object value) { int i = TransItemIndex(SpecialEffectAnimClipEditorModel.GetInstance().CurrentSelect); SpecialEffectAnimClipEditorModel.GetInstance().SetSpeAnimItemDeathType(i, (int)value); }
public override void Visit(EditorControl c) { currCtrl = c as TimeLineViewCtrl; if ( (null == currCtrl) ) { return; } //float itemWidth = c.LastRect.width; float itemHeight = 19.0f; float itemInterval = 3.0f; float rulerTotalLength = currCtrl.rulerTotalPixelLength; float smallScalesNum = currCtrl.CalcSmallScaleCount(rulerTotalLength); float rulerOffset = currCtrl.rulerHorizonPixelOffset; float rulerPixelLength = rulerTotalLength + rulerOffset; float smallScalePixelLen = currCtrl.GetSmallScalePixelLength(); //float bigScalePixelLen = currCtrl.GetBigScalePixelLength(); float smallScaleHeight = itemHeight * 0.3f; float bigScaleHeight = itemHeight * 0.8f; float framesPerSmallScale = currCtrl.framesPerSmallScale; //float framesPerBigScale = framesPerSmallScale * 10f; //时间线款 float itemTimeLineHeight = itemHeight * 0.4f; float itemOffsetHeight = (itemHeight - itemTimeLineHeight) / 3.5f; //根据时间轴列表的滚动条位置,移动可视区域 viewRect = c.LastRect; //viewRect.x += currCtrl.ScrollPos.x; viewRect.y += currCtrl.ScrollPos.y; viewRect.width = rulerOffset + rulerTotalLength; Vector2 viewIndependentUpperLeft = new Vector2(c.LastRect.x, c.LastRect.y); Vector2 viewDependentUpperLeft = new Vector2(viewRect.x, viewRect.y); //Vector2 localMousePos = c.CalcLocalPos(currCtrl.mousePos); EditorGUI.BeginDisabledGroup(!currCtrl.Enable); EditorGUILayout.BeginVertical(c.GetStyle(), c.GetOptions()); float scrollPosY = currCtrl.ScrollPos.y; currCtrl.ScrollPos = GUI.BeginScrollView(c.LastRect, currCtrl.ScrollPos, viewRect, GUI.skin.horizontalScrollbar, GUIStyle.none); currCtrl.ScrollPos = new Vector2(currCtrl.ScrollPos.x, scrollPosY); int i = 0; float x = c.LastRect.x; float y = c.LastRect.y + itemHeight; foreach (var item in currCtrl.Items) { //绘制子时间轴 if (!item.visiable) { i++; continue; } y += itemInterval; y += itemOffsetHeight; float itemTimeLineWidth = currCtrl.CalcPixelLengthByTime(item.length); float itemTimeLineStartX = currCtrl.CalcPixelLengthByTime(item.startTime); Color timeLineItemColor; if (i == currCtrl.LastSelectedItem || currCtrl.IsHighLightBox(i, TimeLineViewCtrl.SIDE_MID)) { timeLineItemColor = item.onSelectedColor; GUI.color = item.onSelectedColor; } else if (!item.enable) { timeLineItemColor = Color.gray; GUI.color = Color.gray; } else { timeLineItemColor = item.color; GUI.color = item.color; } item.lastRect = new Rect(x + itemTimeLineStartX + rulerOffset, y, itemTimeLineWidth, itemTimeLineHeight); Drawing.DrawColorBox(item.lastRect, timeLineItemColor); float boxHeight = itemTimeLineHeight * 1.5f; float boxOffsetHeight = itemTimeLineHeight * 0.25f; Rect leftDragBoxRect = new Rect(item.lastRect.x, item.lastRect.y - boxOffsetHeight, boxHeight, boxHeight); Rect rightDragBoxRect = new Rect(item.lastRect.x + itemTimeLineWidth - boxHeight, item.lastRect.y - boxOffsetHeight, boxHeight, boxHeight); //用于碰撞检测 item.leftDragLastRect = leftDragBoxRect; item.rightDragLastRect = rightDragBoxRect; Color leftDragBoxColor = item.dragBoxColor; Color rightDragBoxColor = item.dragBoxColor; if (currCtrl.IsHighLightBox(i, TimeLineViewCtrl.SIDE_LEFT)) { leftDragBoxColor = item.dragBoxSelectedColor; } if (currCtrl.IsHighLightBox(i, TimeLineViewCtrl.SIDE_RIGHT)) { rightDragBoxColor = item.dragBoxSelectedColor; } Drawing.DrawColorBox(leftDragBoxRect, leftDragBoxColor); Drawing.DrawColorBox(rightDragBoxRect, rightDragBoxColor); //若当前时间轴属于拖动状态绘制标线 if ( currCtrl.IsHighLightBox(i, TimeLineViewCtrl.SIDE_MID) || currCtrl.IsHighLightBox(i, TimeLineViewCtrl.SIDE_LEFT) || currCtrl.IsHighLightBox(i, TimeLineViewCtrl.SIDE_RIGHT) ) { //绘制时间线前后两个基准线 DrawFullViewVLine(item.lastRect.x, Color.white, 1); DrawFullViewVLine(item.lastRect.x + itemTimeLineWidth, Color.white, 1); //绘制基准线时间标 GUI.Box( new Rect(item.lastRect.x + 4, y - 18, 60, 18), currCtrl.Trans2RealTime(item.lastRect.x - currCtrl.LastRect.x).ToString("f2") + "s", SpecialEffectEditorStyle.TimeLineMouseTag); GUI.Box( new Rect(item.lastRect.x + itemTimeLineWidth + 4, y - 18, 60, 18), currCtrl.Trans2RealTime(item.lastRect.x + itemTimeLineWidth - currCtrl.LastRect.x).ToString("f2") + "s", SpecialEffectEditorStyle.TimeLineMouseTag); } y += itemTimeLineHeight; y += itemOffsetHeight; i++; } //绘制子时间轴 GUI.color = Color.white; { //绘制标尺 //标尺主体 GUI.Box(new Rect(c.LastRect.x, viewRect.y, rulerPixelLength, itemHeight), GUIContent.none); //绘制标记 foreach (var tag in currCtrl.Tags) { float tagSize = itemHeight; float tagOffset = currCtrl.CalcPixelLengthByTime(tag.time); float tagCenterX = viewIndependentUpperLeft.x + rulerOffset + tagOffset; float tagX = tagCenterX - tagSize * 0.5f; tag.lastRect.Set(tagX, viewDependentUpperLeft.y, tagSize, tagSize); Color tagColor = tag.color; if (tag.isDragging) { tagColor = tag.onDragColor; } Drawing.DrawColorBox(tag.lastRect, tagColor); DrawFullViewVLine(tagCenterX, tagColor, 1); } //绘制起始线 DrawFullViewVLine(rulerOffset + c.LastRect.x, Color.red, 1); //float mouseLineX = localMousePos.x + viewRect.x + currCtrl.ScrollPos.x; //美术认为目前不需要鼠标时间线 /* * if (false) * { * //绘制鼠标线 * DrawFullViewVLine(mouseLineX, Color.yellow, 1); * * * //绘制鼠标辅助线所指时间 * if (currCtrl.showMouseTag) * { * GUI.Box( * new Rect(mouseLineX + 4, * (localMousePos.y - 18) + viewRect.y, 60, 18), * currCtrl.Trans2RealTime(localMousePos.x + currCtrl.ScrollPos.x).ToString("f2") + "s", * SpecialEffectEditorStyle.TimeLineMouseTag); * } * }*/ //绘制当前帧标线 DrawFullViewVLine(c.LastRect.x + rulerOffset + currCtrl.CalcPixelLengthByTime(currCtrl.CurrPlayTime), Color.gray, 1); //绘制当前帧标线 Vector2 p0 = new Vector2(), p1 = new Vector2(); //绘制小刻度 for (int j = 0; j < smallScalesNum; j++) { float xStart = rulerOffset + c.LastRect.x + j * smallScalePixelLen; float yStart = viewRect.y + (itemHeight - smallScaleHeight); p0 = new Vector2(xStart, yStart); p1 = new Vector2(xStart, yStart + smallScaleHeight); Drawing.DrawLine(p0, p1, Color.black, 1f); //绘制大刻度 if (0 == j % (int)currCtrl.smallScalesPerBigScale) { yStart = viewRect.y + (itemHeight - bigScaleHeight); p0 = new Vector2(xStart, yStart); p1 = new Vector2(xStart, yStart + bigScaleHeight); Drawing.DrawLine(p0, p1, Color.black, 1f); //标尺刻度值 GUI.Box(new Rect(p0.x + 4, viewRect.y, 100, 18), (framesPerSmallScale * j).ToString(), SpecialEffectEditorStyle.RulerNum); } } //绘制总时间线 Vector2 startTimePos = new Vector2(rulerOffset + c.LastRect.x, viewRect.y + itemHeight); Vector2 endTimePos = new Vector2(rulerOffset + c.LastRect.x + currCtrl.CalcPixelLengthByTime(currCtrl.TotalTime), startTimePos.y); Drawing.DrawLine(startTimePos - new Vector2(0, bigScaleHeight), startTimePos, Color.red, 2); Drawing.DrawLine(endTimePos - new Vector2(0, bigScaleHeight), endTimePos, Color.red, 2); Drawing.DrawLine(startTimePos, endTimePos, Color.red, 2); } //绘制标尺 { //绘制多选范围 if (currCtrl.mutiSelectState == TimeLineViewCtrl.MutiSelectState.STATE_DRAGGING_MUTI_SEL_RECT) { GUI.Box(currCtrl.lastMutiSelectRect, GUIContent.none); } } //绘制多选范围 GUI.EndScrollView(); EditorGUILayout.EndVertical(); EditorGUI.EndDisabledGroup(); //处理所有输入交互 HandleInput(); c.UpdateLastRect(); }
static void OnSpeListItemSelect(EditorControl c, int item) { SpecialEffectAnimClipEditorModel.GetInstance().CurrentSelect = item; }
/// <summary> /// Initializes a new instance of the <see cref="OpenFileCommand"/> class. /// </summary> /// <param name="control">The control.</param> public OpenFileCommand(EditorControl control) : base(control) { }
public TopMargin(EditorControl editor) : base(editor) { }
public virtual void Update(EditorControl c, float deltaTime) { }
private void VisitByTextureView(EditorControl c) { ListViewCtrl list = c as ListViewCtrl; Rect tempRect = new Rect(); int listIndex = 0; if (list == null) { return; } if (0 == list.TextureSizeLevel) { list.TextureSizeLevel = 1; } EditorGUILayout.BeginVertical(c.GetStyle(), c.GetOptions()); Vector2 newScrollPos = EditorGUILayout.BeginScrollView(list.ScrollPos, false, true, GUI.skin.horizontalScrollbar, GUI.skin.verticalScrollbar, GUIStyle.none); if (!newScrollPos.Equals(list.ScrollPos)) { c.frameTriggerInfo.isScroll = true; c.frameTriggerInfo.scrollPos = newScrollPos; } list.ScrollPos = newScrollPos; int curColumn = 0; int columns = Mathf.FloorToInt((float)c.LastRect.width / (float)(list.TextureSizeLevel * m_Padding + 20f)); if (columns < 1) { columns = 1; } while (listIndex < list.Items.Count) { EditorGUILayout.BeginHorizontal(); for (; listIndex < list.Items.Count; listIndex++) { if (curColumn >= columns) { curColumn = 0; break; } foreach (var index in list.SelectItems) { if (index == listIndex) { GUI.color = list.Items[index].onSelectTexColor; GUI.Box(list.Items[index].lastRect, GUIContent.none); break; } } GUIContent itemContent = new GUIContent(); if (!string.IsNullOrEmpty(list.Items[listIndex].tooltip)) { itemContent.tooltip = list.Items[listIndex].tooltip; } if (list.Items[listIndex].image != null) { itemContent.image = list.Items[listIndex].image; } EditorGUILayout.BeginVertical(); GUILayout.Box(itemContent, new GUILayoutOption[] { GUILayout.Width(list.TextureSizeLevel * m_Padding), GUILayout.Height(list.TextureSizeLevel * m_Padding) }); SpecialEffectEditorUtility.GetLastRect(ref list.Items[listIndex].lastRect); EditorGUILayout.LabelField(list.Items[listIndex].name, itemStyle, GUILayout.MaxWidth(list.TextureSizeLevel * m_Padding)); SpecialEffectEditorUtility.GetLastRect(ref tempRect); list.Items[listIndex].lastRect.height += tempRect.height; GUI.color = Color.white; EditorGUILayout.EndVertical(); HandleMouseAction(list, listIndex); curColumn++; } EditorGUILayout.EndHorizontal(); } HandleDragAction(list); EditorGUILayout.EndScrollView(); EditorGUILayout.EndVertical(); c.UpdateLastRect(); CheckInputEvent(c); }
internal AffinityManager(EditorControl editor) { this.editor = editor; }
public bool CheckSpelling() { // check spelling using (SpellCheckerForm spellCheckerForm = new SpellCheckerForm(SpellingChecker, EditorControl.FindForm(), false)) { // center the spell-checking form over the document body spellCheckerForm.StartPosition = FormStartPosition.CenterParent; // create word range // TODO: smarter word range for html //TextBoxWordRange wordRange = new TextBoxWordRange(_textBox, _textBox.SelectionLength > 0); HtmlTextBoxWordRange wordRange = new HtmlTextBoxWordRange(_textBox); // check spelling spellCheckerForm.CheckSpelling(wordRange); // return completed status return(spellCheckerForm.Completed); } }
/// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { this.components = new System.ComponentModel.Container(); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(EditorForm)); System.Windows.Forms.TreeNode treeNode1 = new System.Windows.Forms.TreeNode("Level01", 2, 2); System.Windows.Forms.TreeNode treeNode2 = new System.Windows.Forms.TreeNode("Level02", 2, 2); System.Windows.Forms.TreeNode treeNode3 = new System.Windows.Forms.TreeNode("Group01", 1, 1, new System.Windows.Forms.TreeNode[] { treeNode1, treeNode2}); System.Windows.Forms.TreeNode treeNode4 = new System.Windows.Forms.TreeNode("Project [Example01]", new System.Windows.Forms.TreeNode[] { treeNode3}); Chapter24.LevelData levelData1 = new Chapter24.LevelData(); this.toolStrip1 = new System.Windows.Forms.ToolStrip(); this.toolNew = new System.Windows.Forms.ToolStripButton(); this.toolOpen = new System.Windows.Forms.ToolStripButton(); this.toolSave = new System.Windows.Forms.ToolStripButton(); this.toolStripSeparator2 = new System.Windows.Forms.ToolStripSeparator(); this.cmdDrawGrid = new System.Windows.Forms.ToolStripButton(); this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator(); this.toolHitsToClear = new System.Windows.Forms.ToolStripDropDownButton(); this.toolStripMenuItem2 = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripMenuItem3 = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripMenuItem4 = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripMenuItem5 = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripMenuItem6 = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripMenuItem7 = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripMenuItem8 = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripMenuItem9 = new System.Windows.Forms.ToolStripMenuItem(); this.toolStripMenuItem10 = new System.Windows.Forms.ToolStripMenuItem(); this.splitContainer1 = new System.Windows.Forms.SplitContainer(); this.treeView1 = new System.Windows.Forms.TreeView(); this.imageList1 = new System.Windows.Forms.ImageList(this.components); this.toolStrip2 = new System.Windows.Forms.ToolStrip(); this.toolAddNewLevel = new System.Windows.Forms.ToolStripButton(); this.toolCopyLevel = new System.Windows.Forms.ToolStripButton(); this.toolMoveLevelUp = new System.Windows.Forms.ToolStripButton(); this.toolMoveLevelDown = new System.Windows.Forms.ToolStripButton(); this.toolDeleteLevel = new System.Windows.Forms.ToolStripButton(); this.menuStrip1 = new System.Windows.Forms.MenuStrip(); this.mnuFile = new System.Windows.Forms.ToolStripMenuItem(); this.mnuFileNew = new System.Windows.Forms.ToolStripMenuItem(); this.mnuFileOpen = new System.Windows.Forms.ToolStripMenuItem(); this.mnuFileClose = new System.Windows.Forms.ToolStripMenuItem(); this.mnuFileSave = new System.Windows.Forms.ToolStripMenuItem(); this.mnuFileSaveAs = new System.Windows.Forms.ToolStripMenuItem(); this.mnuFileExit = new System.Windows.Forms.ToolStripMenuItem(); this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog(); this.saveFileDialog1 = new System.Windows.Forms.SaveFileDialog(); this.brickBreakerEditorControl1 = new BrickBreakerLevelEditor.EditorControl(); this.toolStrip1.SuspendLayout(); this.splitContainer1.Panel1.SuspendLayout(); this.splitContainer1.Panel2.SuspendLayout(); this.splitContainer1.SuspendLayout(); this.toolStrip2.SuspendLayout(); this.menuStrip1.SuspendLayout(); this.SuspendLayout(); // // toolStrip1 // this.toolStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolNew, this.toolOpen, this.toolSave, this.toolStripSeparator2, this.cmdDrawGrid, this.toolStripSeparator1, this.toolHitsToClear}); this.toolStrip1.Location = new System.Drawing.Point(0, 24); this.toolStrip1.Name = "toolStrip1"; this.toolStrip1.Size = new System.Drawing.Size(594, 25); this.toolStrip1.TabIndex = 0; this.toolStrip1.Text = "toolStrip1"; // // toolNew // this.toolNew.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolNew.Image = ((System.Drawing.Image)(resources.GetObject("toolNew.Image"))); this.toolNew.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolNew.Name = "toolNew"; this.toolNew.Size = new System.Drawing.Size(23, 22); this.toolNew.Text = "Create New Project"; this.toolNew.Click += new System.EventHandler(this.toolNew_Click); // // toolOpen // this.toolOpen.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolOpen.Image = ((System.Drawing.Image)(resources.GetObject("toolOpen.Image"))); this.toolOpen.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolOpen.Name = "toolOpen"; this.toolOpen.Size = new System.Drawing.Size(23, 22); this.toolOpen.Text = "Open Project"; this.toolOpen.Click += new System.EventHandler(this.toolOpen_Click); // // toolSave // this.toolSave.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolSave.Image = ((System.Drawing.Image)(resources.GetObject("toolSave.Image"))); this.toolSave.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolSave.Name = "toolSave"; this.toolSave.Size = new System.Drawing.Size(23, 22); this.toolSave.Text = "Save Project"; this.toolSave.Click += new System.EventHandler(this.toolSave_Click); // // toolStripSeparator2 // this.toolStripSeparator2.Name = "toolStripSeparator2"; this.toolStripSeparator2.Size = new System.Drawing.Size(6, 25); // // cmdDrawGrid // this.cmdDrawGrid.Checked = true; this.cmdDrawGrid.CheckOnClick = true; this.cmdDrawGrid.CheckState = System.Windows.Forms.CheckState.Checked; this.cmdDrawGrid.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.cmdDrawGrid.Image = ((System.Drawing.Image)(resources.GetObject("cmdDrawGrid.Image"))); this.cmdDrawGrid.ImageTransparentColor = System.Drawing.Color.Magenta; this.cmdDrawGrid.Name = "cmdDrawGrid"; this.cmdDrawGrid.Size = new System.Drawing.Size(23, 22); this.cmdDrawGrid.Text = "Show Grid"; this.cmdDrawGrid.CheckedChanged += new System.EventHandler(this.cmdDrawGrid_CheckedChanged); // // toolStripSeparator1 // this.toolStripSeparator1.Name = "toolStripSeparator1"; this.toolStripSeparator1.Size = new System.Drawing.Size(6, 25); // // toolHitsToClear // this.toolHitsToClear.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolHitsToClear.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolStripMenuItem2, this.toolStripMenuItem3, this.toolStripMenuItem4, this.toolStripMenuItem5, this.toolStripMenuItem6, this.toolStripMenuItem7, this.toolStripMenuItem8, this.toolStripMenuItem9, this.toolStripMenuItem10}); this.toolHitsToClear.Image = ((System.Drawing.Image)(resources.GetObject("toolHitsToClear.Image"))); this.toolHitsToClear.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolHitsToClear.Name = "toolHitsToClear"; this.toolHitsToClear.Size = new System.Drawing.Size(29, 22); this.toolHitsToClear.Text = "Hits to Clear"; // // toolStripMenuItem2 // this.toolStripMenuItem2.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem2.Image"))); this.toolStripMenuItem2.Name = "toolStripMenuItem2"; this.toolStripMenuItem2.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem2.Tag = "1"; this.toolStripMenuItem2.Text = "1 Hits"; this.toolStripMenuItem2.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // toolStripMenuItem3 // this.toolStripMenuItem3.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem3.Image"))); this.toolStripMenuItem3.Name = "toolStripMenuItem3"; this.toolStripMenuItem3.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem3.Tag = "2"; this.toolStripMenuItem3.Text = "2 Hits"; this.toolStripMenuItem3.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // toolStripMenuItem4 // this.toolStripMenuItem4.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem4.Image"))); this.toolStripMenuItem4.Name = "toolStripMenuItem4"; this.toolStripMenuItem4.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem4.Tag = "3"; this.toolStripMenuItem4.Text = "3 Hits"; this.toolStripMenuItem4.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // toolStripMenuItem5 // this.toolStripMenuItem5.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem5.Image"))); this.toolStripMenuItem5.Name = "toolStripMenuItem5"; this.toolStripMenuItem5.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem5.Tag = "4"; this.toolStripMenuItem5.Text = "4 Hits"; this.toolStripMenuItem5.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // toolStripMenuItem6 // this.toolStripMenuItem6.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem6.Image"))); this.toolStripMenuItem6.Name = "toolStripMenuItem6"; this.toolStripMenuItem6.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem6.Tag = "5"; this.toolStripMenuItem6.Text = "5 Hits"; this.toolStripMenuItem6.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // toolStripMenuItem7 // this.toolStripMenuItem7.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem7.Image"))); this.toolStripMenuItem7.Name = "toolStripMenuItem7"; this.toolStripMenuItem7.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem7.Tag = "6"; this.toolStripMenuItem7.Text = "6 Hits"; this.toolStripMenuItem7.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // toolStripMenuItem8 // this.toolStripMenuItem8.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem8.Image"))); this.toolStripMenuItem8.Name = "toolStripMenuItem8"; this.toolStripMenuItem8.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem8.Tag = "7"; this.toolStripMenuItem8.Text = "7 Hits"; this.toolStripMenuItem8.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // toolStripMenuItem9 // this.toolStripMenuItem9.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem9.Image"))); this.toolStripMenuItem9.Name = "toolStripMenuItem9"; this.toolStripMenuItem9.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem9.Tag = "8"; this.toolStripMenuItem9.Text = "8 Hits"; this.toolStripMenuItem9.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // toolStripMenuItem10 // this.toolStripMenuItem10.Image = ((System.Drawing.Image)(resources.GetObject("toolStripMenuItem10.Image"))); this.toolStripMenuItem10.Name = "toolStripMenuItem10"; this.toolStripMenuItem10.Size = new System.Drawing.Size(112, 22); this.toolStripMenuItem10.Tag = "9"; this.toolStripMenuItem10.Text = "9 Hits"; this.toolStripMenuItem10.Click += new System.EventHandler(this.toolStripMenuItem2_Click); // // splitContainer1 // this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill; this.splitContainer1.FixedPanel = System.Windows.Forms.FixedPanel.Panel1; this.splitContainer1.Location = new System.Drawing.Point(0, 49); this.splitContainer1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.splitContainer1.Name = "splitContainer1"; // // splitContainer1.Panel1 // this.splitContainer1.Panel1.Controls.Add(this.treeView1); this.splitContainer1.Panel1.Controls.Add(this.toolStrip2); // // splitContainer1.Panel2 // this.splitContainer1.Panel2.AutoScroll = true; this.splitContainer1.Panel2.BackColor = System.Drawing.SystemColors.ControlDark; this.splitContainer1.Panel2.Controls.Add(this.brickBreakerEditorControl1); this.splitContainer1.Size = new System.Drawing.Size(594, 412); this.splitContainer1.SplitterDistance = 195; this.splitContainer1.SplitterWidth = 3; this.splitContainer1.TabIndex = 1; // // treeView1 // this.treeView1.Dock = System.Windows.Forms.DockStyle.Fill; this.treeView1.HideSelection = false; this.treeView1.ImageIndex = 0; this.treeView1.ImageList = this.imageList1; this.treeView1.Location = new System.Drawing.Point(0, 25); this.treeView1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.treeView1.Name = "treeView1"; treeNode1.ImageIndex = 2; treeNode1.Name = "Node2"; treeNode1.SelectedImageIndex = 2; treeNode1.Text = "Level01"; treeNode2.ImageIndex = 2; treeNode2.Name = "Node3"; treeNode2.SelectedImageIndex = 2; treeNode2.Text = "Level02"; treeNode3.ImageIndex = 1; treeNode3.Name = "Node1"; treeNode3.SelectedImageIndex = 1; treeNode3.Text = "Group01"; treeNode4.Name = "Node0"; treeNode4.Text = "Project [Example01]"; treeNode4.ToolTipText = "c:\\projects\\XNA Book\\Genre\\BrickBreaker\\levels\\Example01.bbp"; this.treeView1.Nodes.AddRange(new System.Windows.Forms.TreeNode[] { treeNode4}); this.treeView1.SelectedImageIndex = 0; this.treeView1.Size = new System.Drawing.Size(195, 387); this.treeView1.TabIndex = 0; this.treeView1.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.treeView1_AfterSelect); // // imageList1 // this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream"))); this.imageList1.TransparentColor = System.Drawing.Color.Transparent; this.imageList1.Images.SetKeyName(0, "project.png"); this.imageList1.Images.SetKeyName(1, ""); this.imageList1.Images.SetKeyName(2, "level.png"); // // toolStrip2 // this.toolStrip2.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolAddNewLevel, this.toolCopyLevel, this.toolMoveLevelUp, this.toolMoveLevelDown, this.toolDeleteLevel}); this.toolStrip2.Location = new System.Drawing.Point(0, 0); this.toolStrip2.Name = "toolStrip2"; this.toolStrip2.Size = new System.Drawing.Size(195, 25); this.toolStrip2.TabIndex = 1; this.toolStrip2.Text = "toolStrip2"; // // toolAddNewLevel // this.toolAddNewLevel.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolAddNewLevel.Image = ((System.Drawing.Image)(resources.GetObject("toolAddNewLevel.Image"))); this.toolAddNewLevel.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolAddNewLevel.Name = "toolAddNewLevel"; this.toolAddNewLevel.Size = new System.Drawing.Size(23, 22); this.toolAddNewLevel.Text = "Add New Level"; this.toolAddNewLevel.Click += new System.EventHandler(this.toolAddNewLevel_Click); // // toolCopyLevel // this.toolCopyLevel.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolCopyLevel.Image = ((System.Drawing.Image)(resources.GetObject("toolCopyLevel.Image"))); this.toolCopyLevel.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolCopyLevel.Name = "toolCopyLevel"; this.toolCopyLevel.Size = new System.Drawing.Size(23, 22); this.toolCopyLevel.Text = "toolStripButton1"; this.toolCopyLevel.ToolTipText = "Copy Level"; this.toolCopyLevel.Click += new System.EventHandler(this.toolCopyLevel_Click); // // toolMoveLevelUp // this.toolMoveLevelUp.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolMoveLevelUp.Image = ((System.Drawing.Image)(resources.GetObject("toolMoveLevelUp.Image"))); this.toolMoveLevelUp.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolMoveLevelUp.Name = "toolMoveLevelUp"; this.toolMoveLevelUp.Size = new System.Drawing.Size(23, 22); this.toolMoveLevelUp.Text = "Move Level Up"; this.toolMoveLevelUp.Click += new System.EventHandler(this.toolMoveLevelUp_Click); // // toolMoveLevelDown // this.toolMoveLevelDown.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolMoveLevelDown.Image = ((System.Drawing.Image)(resources.GetObject("toolMoveLevelDown.Image"))); this.toolMoveLevelDown.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolMoveLevelDown.Name = "toolMoveLevelDown"; this.toolMoveLevelDown.Size = new System.Drawing.Size(23, 22); this.toolMoveLevelDown.Text = "Move Level Down"; this.toolMoveLevelDown.Click += new System.EventHandler(this.toolMoveLevelDown_Click); // // toolDeleteLevel // this.toolDeleteLevel.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image; this.toolDeleteLevel.Image = ((System.Drawing.Image)(resources.GetObject("toolDeleteLevel.Image"))); this.toolDeleteLevel.ImageTransparentColor = System.Drawing.Color.Magenta; this.toolDeleteLevel.Name = "toolDeleteLevel"; this.toolDeleteLevel.Size = new System.Drawing.Size(23, 22); this.toolDeleteLevel.Text = "Delete Level"; this.toolDeleteLevel.Click += new System.EventHandler(this.toolDeleteLevel_Click); // // menuStrip1 // this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.mnuFile}); this.menuStrip1.Location = new System.Drawing.Point(0, 0); this.menuStrip1.Name = "menuStrip1"; this.menuStrip1.Padding = new System.Windows.Forms.Padding(4, 2, 0, 2); this.menuStrip1.Size = new System.Drawing.Size(594, 24); this.menuStrip1.TabIndex = 2; this.menuStrip1.Text = "menuStrip1"; // // mnuFile // this.mnuFile.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.mnuFileNew, this.mnuFileOpen, this.mnuFileClose, this.mnuFileSave, this.mnuFileSaveAs, this.mnuFileExit}); this.mnuFile.Name = "mnuFile"; this.mnuFile.Size = new System.Drawing.Size(35, 20); this.mnuFile.Text = "&File"; // // mnuFileNew // this.mnuFileNew.Name = "mnuFileNew"; this.mnuFileNew.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.N))); this.mnuFileNew.Size = new System.Drawing.Size(207, 22); this.mnuFileNew.Text = "&New"; this.mnuFileNew.Click += new System.EventHandler(this.mnuFileNew_Click); // // mnuFileOpen // this.mnuFileOpen.Name = "mnuFileOpen"; this.mnuFileOpen.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.O))); this.mnuFileOpen.Size = new System.Drawing.Size(207, 22); this.mnuFileOpen.Text = "&Open"; this.mnuFileOpen.Click += new System.EventHandler(this.mnuFileOpen_Click); // // mnuFileClose // this.mnuFileClose.Name = "mnuFileClose"; this.mnuFileClose.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.F4))); this.mnuFileClose.Size = new System.Drawing.Size(207, 22); this.mnuFileClose.Text = "&Close"; // // mnuFileSave // this.mnuFileSave.Name = "mnuFileSave"; this.mnuFileSave.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.S))); this.mnuFileSave.Size = new System.Drawing.Size(207, 22); this.mnuFileSave.Text = "&Save"; this.mnuFileSave.Click += new System.EventHandler(this.mnuFileSave_Click); // // mnuFileSaveAs // this.mnuFileSaveAs.Name = "mnuFileSaveAs"; this.mnuFileSaveAs.ShortcutKeys = ((System.Windows.Forms.Keys)(((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Shift) | System.Windows.Forms.Keys.S))); this.mnuFileSaveAs.Size = new System.Drawing.Size(207, 22); this.mnuFileSaveAs.Text = "Save &As ..."; this.mnuFileSaveAs.Click += new System.EventHandler(this.mnuFileSaveAs_Click); // // mnuFileExit // this.mnuFileExit.Name = "mnuFileExit"; this.mnuFileExit.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Alt | System.Windows.Forms.Keys.F4))); this.mnuFileExit.Size = new System.Drawing.Size(207, 22); this.mnuFileExit.Text = "E&xit"; this.mnuFileExit.Click += new System.EventHandler(this.mnuFileExit_Click); // // openFileDialog1 // this.openFileDialog1.FileName = "openFileDialog1"; this.openFileDialog1.Filter = "BrickBreaker Projects|*.bbp|All Files|*.*"; // // saveFileDialog1 // this.saveFileDialog1.Filter = "BrickBreaker Projects|*.bbp|All Files|*.*"; // // brickBreakerEditorControl1 // this.brickBreakerEditorControl1.DrawGrid = true; levelData1.BrickHeight = 20; levelData1.BrickWidth = 40; levelData1.Changed = true; this.brickBreakerEditorControl1.LevelData = levelData1; this.brickBreakerEditorControl1.Location = new System.Drawing.Point(0, 0); this.brickBreakerEditorControl1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.brickBreakerEditorControl1.Name = "brickBreakerEditorControl1"; this.brickBreakerEditorControl1.NumHitsToClear = 1; this.brickBreakerEditorControl1.Size = new System.Drawing.Size(480, 480); this.brickBreakerEditorControl1.TabIndex = 0; // // EditorForm // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(594, 461); this.Controls.Add(this.splitContainer1); this.Controls.Add(this.toolStrip1); this.Controls.Add(this.menuStrip1); this.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.Name = "EditorForm"; this.Text = "BrickBreaker Level Editor"; this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.BrickBreakerEditor_FormClosing); this.toolStrip1.ResumeLayout(false); this.toolStrip1.PerformLayout(); this.splitContainer1.Panel1.ResumeLayout(false); this.splitContainer1.Panel1.PerformLayout(); this.splitContainer1.Panel2.ResumeLayout(false); this.splitContainer1.ResumeLayout(false); this.toolStrip2.ResumeLayout(false); this.toolStrip2.PerformLayout(); this.menuStrip1.ResumeLayout(false); this.menuStrip1.PerformLayout(); this.ResumeLayout(false); this.PerformLayout(); }