From b652b0c2f8eb74a1bf589698a8db41cbface731a Mon Sep 17 00:00:00 2001 From: Stefan Sauer Date: Thu, 4 Nov 2010 10:46:43 +0200 Subject: [PATCH] info: show stream tags as multiline label --- mediainfo/src/mi-info.vala | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/mediainfo/src/mi-info.vala b/mediainfo/src/mi-info.vala index 292e6d8..1e69b7e 100644 --- a/mediainfo/src/mi-info.vala +++ b/mediainfo/src/mi-info.vala @@ -287,6 +287,20 @@ public class MediaInfo.Info : VBox row++; } + if ((s = (Structure)sinfo.get_tags ()) != null) { + // FIXME: use treeview inside scrolled window + label = new Label ("Tags:"); + label.set_alignment (1.0f, 0.0f); + table.attach (label, 0, 1, row, row+1, fill, fill, 0, 0); + str = s.to_string (); + str = str[8:-1].compress().replace(",","\n"); + label = new Label(str); + label.set_ellipsize (Pango.EllipsizeMode.END); + label.set_alignment (0.0f, 0.5f); + table.attach (label, 1, 2, row, row+1, fill_exp, 0, 0, 1); + row++; + } + video_streams.append_page (table, new Label (@"video $i")); } video_streams.show_all(); @@ -363,6 +377,20 @@ public class MediaInfo.Info : VBox row++; } + if ((s = (Structure)sinfo.get_tags ()) != null) { + // FIXME: use treeview inside scrolled window + label = new Label ("Tags:"); + label.set_alignment (1.0f, 0.0f); + table.attach (label, 0, 1, row, row+1, fill, fill, 0, 0); + str = s.to_string (); + str = str[8:-1].compress().replace(",","\n"); + label = new Label(str); + label.set_ellipsize (Pango.EllipsizeMode.END); + label.set_alignment (0.0f, 0.5f); + table.attach (label, 1, 2, row, row+1, fill_exp, 0, 0, 1); + row++; + } + audio_streams.append_page (table, new Label (@"audio $i")); } audio_streams.show_all(); -- 2.7.4