(card *Card)
| 725 | } |
| 726 | |
| 727 | func NewNoteContents(card *Card) *NoteContents { |
| 728 | |
| 729 | nc := &NoteContents{ |
| 730 | DefaultContents: newDefaultContents(card), |
| 731 | } |
| 732 | |
| 733 | nc.Label = NewLabel("New Note", nil, true, AlignLeft) |
| 734 | nc.Label.Editable = true |
| 735 | nc.Label.Property = card.Properties.Get("description") |
| 736 | |
| 737 | nc.Label.OnChange = func() { |
| 738 | commonTextEditingResizing(nc.Label, card) |
| 739 | } |
| 740 | |
| 741 | row := nc.container.AddRow(AlignLeft) |
| 742 | row.Add("icon", NewGUIImage(nil, &sdl.FRect{112, 160, 32, 32}, globals.GUITexture.Texture, true)) |
| 743 | row.Add("label", nc.Label) |
| 744 | |
| 745 | return nc |
| 746 | |
| 747 | } |
| 748 | |
| 749 | func (nc *NoteContents) AutosetSize() { |
| 750 |
no test coverage detected