private bool[,] RenderTextBox(IViewBoxModel view, UiElement textBoxContent) { bool[,] viewMatrix; if (textBoxContent.isDisabled) { viewMatrix = Helper.createBoxDeaktivatedUpDown(view.ViewBox.Height, view.ViewBox.Width); } else { viewMatrix = Helper.createBox(view.ViewBox.Height, view.ViewBox.Width); //erstmal eine eckige Matrix } //Ecke links oben abrunden Debug.Print(viewMatrix.GetLength(0).ToString()); Debug.Print(viewMatrix.GetLength(1).ToString()); if (viewMatrix.GetLength(0) <= 0 || viewMatrix.GetLength(1) <= 0) { return(new bool[0, 0]); } viewMatrix[0, 0] = false; if (viewMatrix.GetLength(1) > 1) { viewMatrix[1, 0] = false; } if (viewMatrix.GetLength(0) > 1) { viewMatrix[0, 1] = false; } if (viewMatrix.GetLength(0) > 1 && viewMatrix.GetLength(1) > 1) { viewMatrix[1, 1] = true; } BrailleIOViewRange tmpBoxView = new BrailleIOViewRange(view.ViewBox.Left, view.ViewBox.Top, view.ViewBox.Width, view.ViewBox.Height); tmpBoxView.Name = "_B_" + textBoxContent.screenName + view.ViewBox.Left + view.ViewBox.Top + view.ViewBox.Width + view.ViewBox.Height; // tmpBoxView.SetText(textBoxText); tmpBoxView.SetMatrix(viewMatrix); // tmpBoxView.ShowScrollbars = true; tmpBoxView.SetYOffset(0); tmpBoxView.SetZIndex(2); object cM = textBoxContent.text as object; IViewBoxModel tmpModel = tmpBoxView as IViewBoxModel; callAllPreHooks(ref tmpModel, ref cM); tmpBoxView = tmpBoxView as BrailleIOViewRange; BrailleIOMediator brailleIOMediator = BrailleIOMediator.Instance; BrailleIOScreen screen = (BrailleIOScreen)brailleIOMediator.GetView(textBoxContent.screenName); if (screen != null) { BrailleIOViewRange viewRange = screen.GetViewRange(tmpBoxView.Name); if (viewRange == null) { ((BrailleIOScreen)brailleIOMediator.GetView(textBoxContent.screenName)).AddViewRange(tmpBoxView.Name, tmpBoxView); } } callAllPostHooks(tmpBoxView, cM, ref viewMatrix, false); return(viewMatrix); }