[chronojump] New config mode: EncoderCaptureShowOnlyBars
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump] New config mode: EncoderCaptureShowOnlyBars
- Date: Thu, 30 Jul 2015 17:38:09 +0000 (UTC)
commit e17264ba0e99a13a5629bc1cb5290d656155c0b1
Author: Xavier de Blas <xaviblas gmail com>
Date: Thu Jul 30 19:37:31 2015 +0200
New config mode: EncoderCaptureShowOnlyBars
chronojump_config.txt | 5 ++
glade/chronojump.glade | 130 +++++++++++++++++++++++++++++++++++-------------
src/config.cs | 5 ++
src/gui/encoder.cs | 3 +
src/gui/networks.cs | 5 ++
5 files changed, 113 insertions(+), 35 deletions(-)
---
diff --git a/chronojump_config.txt b/chronojump_config.txt
index 749eef8..24bbee6 100644
--- a/chronojump_config.txt
+++ b/chronojump_config.txt
@@ -44,6 +44,11 @@ AutodetectPort=DISCARDFIRST
#default: OnlyEncoder=FALSE
OnlyEncoder=TRUE
+#On encoder capture hide below table and side vpaned_encoder_capture_video_and_set_graph
+#Note if this is true, then video will not be shown
+#default: EncoderCaptureShowOnlyBars=FALSE
+EncoderCaptureShowOnlyBars=FALSE
+
#Hide left person box. Select person by a label and button on the top
#default: PersonWinHide=FALSE
PersonWinHide=TRUE
diff --git a/glade/chronojump.glade b/glade/chronojump.glade
index 2d6f52b..db4012e 100644
--- a/glade/chronojump.glade
+++ b/glade/chronojump.glade
@@ -7648,6 +7648,9 @@ after time</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
</child>
<child>
@@ -9050,6 +9053,9 @@ after time</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
<packing>
<property name="position">2</property>
@@ -10093,6 +10099,9 @@ after time</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
<packing>
<property name="position">4</property>
@@ -15571,40 +15580,34 @@ on current Chronojump version.</property>
<property name="can_focus">True</property>
<property name="position">400</property>
<child>
- <widget class="GtkVPaned" id="vpaned3">
+ <widget class="GtkVPaned" id="vpaned_encoder_main">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="position">200</property>
<child>
- <widget class="GtkAlignment" id="alignment36">
- <property name="height_request">150</property>
+ <widget class="GtkAlignment"
id="alignment_encoder_capture_curves_bars_drawingarea">
+ <property name="height_request">170</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="border_width">4</property>
<child>
+ <widget class="GtkVBox" id="vbox41">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">10</property>
+ <child>
<widget class="GtkDrawingArea"
id="encoder_capture_curves_bars_drawingarea">
<property name="visible">True</property>
<property name="can_focus">False</property>
<signal name="configure_event"
handler="on_encoder_capture_curves_bars_drawingarea_configure_event" swapped="no"/>
<signal name="expose_event"
handler="on_encoder_capture_curves_bars_drawingarea_expose_event" swapped="no"/>
</widget>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
</child>
- </widget>
- <packing>
- <property name="resize">True</property>
- <property name="shrink">False</property>
- </packing>
- </child>
- <child>
- <widget class="GtkAlignment" id="alignment19">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="border_width">4</property>
- <child>
- <widget class="GtkVBox" id="vbox8">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="spacing">2</property>
<child>
<widget class="GtkHBox" id="hbox156">
<property name="visible">True</property>
@@ -15632,7 +15635,7 @@ on current Chronojump version.</property>
<widget class="GtkHBox"
id="hbox_encoder_capture_curves_save_all_none">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="spacing">8</property>
+ <property name="spacing">16</property>
<child>
<widget class="GtkLabel" id="label108">
<property name="visible">True</property>
@@ -15718,11 +15721,26 @@ on current Chronojump version.</property>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
- <property name="position">0</property>
+ <property name="position">1</property>
</packing>
</child>
+ </widget>
+ </child>
+ </widget>
+ <packing>
+ <property name="resize">True</property>
+ <property name="shrink">False</property>
+ </packing>
+ </child>
+ <child>
+ <widget class="GtkAlignment"
id="alignment_treeview_encoder_capture_curves">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="border_width">4</property>
<child>
- <widget class="GtkVBox" id="vbox41">
+ <widget class="GtkVBox"
id="vbox_treview_encoder_capture_curves">
+ <property name="width_request">200</property>
+ <property name="height_request">145</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="spacing">2</property>
@@ -15733,8 +15751,6 @@ on current Chronojump version.</property>
<property name="spacing">4</property>
<child>
<widget class="GtkScrolledWindow"
id="scrolledwindow2">
- <property name="width_request">200</property>
- <property name="height_request">165</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property
name="hscrollbar_policy">automatic</property>
@@ -15763,13 +15779,6 @@ on current Chronojump version.</property>
</packing>
</child>
</widget>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
- </child>
- </widget>
</child>
</widget>
<packing>
@@ -15784,7 +15793,7 @@ on current Chronojump version.</property>
</packing>
</child>
<child>
- <widget class="GtkVPaned" id="vpaned2">
+ <widget class="GtkVPaned"
id="vpaned_encoder_capture_video_and_set_graph">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="position">200</property>
@@ -21653,6 +21662,9 @@ by you</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
</child>
</widget>
@@ -22595,6 +22607,9 @@ by you</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
</child>
</widget>
@@ -24029,6 +24044,9 @@ by you</property>
<placeholder/>
</child>
<child>
+ <placeholder/>
+ </child>
+ <child>
<widget class="GtkButton" id="button_video_url">
<property name="visible">True</property>
<property name="can_focus">True</property>
@@ -24520,6 +24538,9 @@ by you</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
<packing>
<property name="expand">True</property>
@@ -36074,6 +36095,24 @@ options</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
</child>
</widget>
@@ -37805,6 +37844,18 @@ To differentiate between male and female, use the values 1/0, or m/f, or M/F on
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
</child>
</widget>
@@ -39163,9 +39214,6 @@ To differentiate between male and female, use the values 1/0, or m/f, or M/F on
<placeholder/>
</child>
<child>
- <placeholder/>
- </child>
- <child>
<widget class="GtkLabel" id="label218">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -40107,6 +40155,9 @@ To differentiate between male and female, use the values 1/0, or m/f, or M/F on
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
</child>
</widget>
@@ -43836,6 +43887,9 @@ It starts before and arrives there with some speed.</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
<packing>
<property name="left_attach">2</property>
@@ -44442,6 +44496,9 @@ It starts before and arrives there with some speed.</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
</child>
</widget>
@@ -45063,6 +45120,9 @@ It starts before and arrives there with some speed.</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
</child>
</widget>
diff --git a/src/config.cs b/src/config.cs
index 918c932..7a88451 100644
--- a/src/config.cs
+++ b/src/config.cs
@@ -32,6 +32,7 @@ public class Config
public bool UseVideo;
public AutodetectPortEnum AutodetectPort;
public bool OnlyEncoder;
+ public bool EncoderCaptureShowOnlyBars;
public bool PersonWinHide;
public bool EncoderAnalyzeHide;
public EncoderConfiguration Econf;
@@ -45,6 +46,7 @@ public class Config
UseVideo = true;
AutodetectPort = AutodetectPortEnum.ACTIVE;
OnlyEncoder = false;
+ EncoderCaptureShowOnlyBars = false;
PersonWinHide = false;
EncoderAnalyzeHide = false;
Econf = null;
@@ -82,6 +84,8 @@ public class Config
Enum.Parse(typeof(AutodetectPortEnum), parts[1]);
else if(parts[0] == "OnlyEncoder" && Util.StringToBool(parts[1]))
OnlyEncoder = true;
+ else if(parts[0] == "EncoderCaptureShowOnlyBars" &&
Util.StringToBool(parts[1]))
+ EncoderCaptureShowOnlyBars = true;
else if(parts[0] == "PersonWinHide" && Util.StringToBool(parts[1]))
PersonWinHide = true;
else if(parts[0] == "EncoderAnalyzeHide" &&
Util.StringToBool(parts[1]))
@@ -149,6 +153,7 @@ public class Config
"UseVideo = " + UseVideo.ToString() + "\n" +
"AutodetectPort = " + AutodetectPort.ToString() + "\n" +
"OnlyEncoder = " + OnlyEncoder.ToString() + "\n" +
+ "EncoderCaptureShowOnlyBars = " + EncoderCaptureShowOnlyBars.ToString() +
"\n" +
"PersonWinHide = " + PersonWinHide.ToString() + "\n" +
"EncoderAnalyzeHide = " + EncoderAnalyzeHide.ToString() + "\n" +
"Econf = " + econfStr + "\n" +
diff --git a/src/gui/encoder.cs b/src/gui/encoder.cs
index 77293d9..ff89159 100644
--- a/src/gui/encoder.cs
+++ b/src/gui/encoder.cs
@@ -79,6 +79,7 @@ public partial class ChronoJumpWindow
[Widget] Gtk.Label label_encoder_curve_action;
[Widget] Gtk.Button button_encoder_delete_signal;
+ [Widget] Gtk.VPaned vpaned_encoder_capture_video_and_set_graph;
//encoder video
[Widget] Gtk.Alignment alignment_video_encoder;
@@ -178,10 +179,12 @@ public partial class ChronoJumpWindow
[Widget] Gtk.Image image_encoder_analyze;
[Widget] Gtk.ProgressBar encoder_pulsebar_analyze;
+ [Widget] Gtk.Alignment alignment_treeview_encoder_capture_curves;
[Widget] Gtk.TreeView treeview_encoder_capture_curves;
[Widget] Gtk.TreeView treeview_encoder_analyze_curves;
[Widget] Gtk.DrawingArea encoder_capture_signal_drawingarea;
+
[Widget] Gtk.DrawingArea encoder_capture_curves_bars_drawingarea;
Gdk.Pixmap encoder_capture_signal_pixmap = null;
Gdk.Pixmap encoder_capture_curves_bars_pixmap = null;
diff --git a/src/gui/networks.cs b/src/gui/networks.cs
index 5a68708..10909da 100644
--- a/src/gui/networks.cs
+++ b/src/gui/networks.cs
@@ -80,6 +80,11 @@ public partial class ChronoJumpWindow
if(config.OnlyEncoder)
select_menuitem_mode_toggled(menuitem_modes.POWER);
+ if(config.EncoderCaptureShowOnlyBars) {
+ vpaned_encoder_capture_video_and_set_graph.Visible = false;
+ alignment_treeview_encoder_capture_curves.Visible = false;
+ }
+
if(config.PersonWinHide) {
//vbox_persons.Visible = false;
notebook_session_person.Visible = false;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]