public DrawVertexButton(int width, int height, int positionX, int positionY, InputCountVertexForm inputCountForm , MatrixGraph matrixGraph, StartForm.StartForm startForm, string buttonText = "Create vertexes") { ForeColor = Color.Black; this.BackColor = Color.Orange; Font = new System.Drawing.Font("Comic Sans MS", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(204))); FlatStyle = System.Windows.Forms.FlatStyle.Popup; this.Text = buttonText; this.Size = new System.Drawing.Size(width, height); this.Location = new System.Drawing.Point(positionX, positionY); this.inputCountForm = inputCountForm; this.matrixGraph = matrixGraph; vertexDraws = new List <VertexDraw>(); edgeDraws = new List <EdgeDraw>(); initialGraph = new InitialGraph(vertexDraws, edgeDraws, matrixGraph); matrix = new List <List <CellBox> >(); Click += new EventHandler(ButtonClick); this.startForm = startForm; }
public InputCountVertexForm(StartForm.StartForm startForm) { InitializeComponent(); StartPosition = FormStartPosition.CenterScreen; Text = "GraphVizualizer / Matrix"; this.BackColor = Color.DarkGray; matrixPanel = new MatrixWeightTablePanel(350, 290, Width / 2 - 190, 155); matrixGraph = new MatrixGraph(matrixPanel); inputBox = new InputCountBox(300, 20, 200, 100); Controls.Add(inputBox); infoText = new InfoTextLabel(300, 30, 200, 80); Controls.Add(infoText); confirmButton = new ConfirmButton(100, 30, 500, 100, inputBox, matrixGraph); Controls.Add(confirmButton); backToMenuOfInputButton = new BackToMenuFromInputButton(matrixGraph, this); Controls.Add(backToMenuOfInputButton); drawVertexButton = new DrawVertexButton(100, 30, 600, 100, this, matrixGraph, startForm); Controls.Add(drawVertexButton); Controls.Add(matrixPanel); }
public InitialGraph(List <VertexDraw> vertexDraws, List <EdgeDraw> edgeDraws, MatrixGraph matrixGraph) { this.vertexDraws = vertexDraws; this.edgeDraws = edgeDraws; this.matrixGraph = matrixGraph; collisionVertex = new CollisionVertex(); converter = new Converter(); }
public BackToMenuFromInputButton(MatrixGraph matrixGraph, InputCountVertexForm inputCountVertexForm, string buttonText = "Menu") : base(buttonText) { ForeColor = Color.Black; this.BackColor = Color.Orange; Font = new System.Drawing.Font("Comic Sans MS", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(204))); FlatStyle = System.Windows.Forms.FlatStyle.Popup; Text = buttonText; Location = new System.Drawing.Point(10, 410); this.inputCountVertexForm = inputCountVertexForm; this.matrixGraph = matrixGraph; }
public ConfirmButton(int width, int height, int positionX, int positionY, InputCountBox inputCountBox , MatrixGraph matrixGraph, string buttonText = "OK") { ForeColor = Color.Black; this.BackColor = Color.Orange; Font = new System.Drawing.Font("Comic Sans MS", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(204))); FlatStyle = System.Windows.Forms.FlatStyle.Popup; this.Text = buttonText; this.Size = new System.Drawing.Size(width, height); this.Location = new System.Drawing.Point(positionX, positionY); this.inputCountBox = inputCountBox; Click += new EventHandler(ButtonClick); this.matrixGraph = matrixGraph; }