-
Notifications
You must be signed in to change notification settings - Fork 1
/
frmMeme.cs
31 lines (26 loc) · 831 Bytes
/
frmMeme.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
using System.Collections.Generic;
using System.Drawing;
using System.Windows.Forms;
namespace MemeGen
{
public partial class frmMeme : Form
{
public frmMeme(ICollection<(Image, string)> steps)
{
InitializeComponent();
foreach ((Image, string) step in steps)
{
StepDisplay display = new StepDisplay(step.Item1, step.Item2);
RowStyle style = new RowStyle(SizeType.Absolute, display.Height);
if (Table.Controls.Count > 0)
{
Table.RowCount += 1;
Table.RowStyles.Add(style);
}
else
Table.RowStyles[0] = style;
Table.Controls.Add(display, 0, Table.Controls.Count);
}
}
}
}