Skip to content

Commit

Permalink
fix(Granite.TextStyle): Replace deprecated usage modes
Browse files Browse the repository at this point in the history
  • Loading branch information
Cleiton Floss committed Jan 17, 2018
1 parent dcfe4e5 commit fef4db4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions src/view/BudgetOverview.vala
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ namespace Envelope.View {
pack_start (summary_container);

var summary_title = new Gtk.Label(_("Your budget right now:"));
set_class (summary_title, Granite.StyleClass.H1_TEXT);
set_class (summary_title, Granite.STYLE_CLASS_H1_LABEL);
//Granite.Widgets.Utils.set_theming (summary_title, STYLE_CLASS_OVERVIEW_TITLE, "overview-title", Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
summary_container.pack_start (summary_title);

Expand All @@ -108,7 +108,7 @@ namespace Envelope.View {
in_out_box.pack_start (inflow_box);

var inflow_label = new Gtk.Label (_("Inflow:"));
set_class (inflow_label, Granite.StyleClass.H2_TEXT);
set_class (inflow_label, Granite.STYLE_CLASS_H2_LABEL);
//Granite.Widgets.Utils.set_theming (inflow_label, STYLE_CLASS_OVERVIEW, "overview", Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
inflow_box.pack_start (inflow_label, false);

Expand All @@ -120,7 +120,7 @@ namespace Envelope.View {
in_out_box.pack_start (outflow_box);

var outflow_label = new Gtk.Label (_("Outflow:"));
set_class (outflow_label, Granite.StyleClass.H2_TEXT);
set_class (outflow_label, Granite.STYLE_CLASS_H2_LABEL);
//Granite.Widgets.Utils.set_theming (outflow_label, STYLE_CLASS_OVERVIEW, "overview", Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
outflow_box.pack_start (outflow_label, false);

Expand All @@ -132,7 +132,7 @@ namespace Envelope.View {
in_out_box.pack_start (remaining_box);

var remaining_label = new Gtk.Label (_("Remaining this month:"));
set_class (remaining_label, Granite.StyleClass.H2_TEXT);
set_class (remaining_label, Granite.STYLE_CLASS_H2_LABEL);
//Granite.Widgets.Utils.set_theming (remaining_label, STYLE_CLASS_OVERVIEW, "overview", Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
remaining_box.pack_start (remaining_label, false);

Expand Down Expand Up @@ -178,7 +178,7 @@ namespace Envelope.View {
if (!transactions.is_empty) {

var category_label = new Gtk.Label (category.name);
set_class (category_label, Granite.StyleClass.H2_TEXT);
set_class (category_label, Granite.STYLE_CLASS_H2_LABEL);
category_label.xalign = 1.0f;

var category_summary_str = "";
Expand Down Expand Up @@ -206,7 +206,7 @@ namespace Envelope.View {


var category_summary = new Gtk.Label (category_summary_str);
set_class (category_summary, Granite.StyleClass.H3_TEXT);
set_class (category_summary, Granite.STYLE_CLASS_H3_LABEL);
category_summary.xalign = 0.0f;

charts_container.attach_next_to (category_label, null, Gtk.PositionType.BOTTOM, 1, 1);
Expand Down
2 changes: 1 addition & 1 deletion src/view/CategoryProperties.vala
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ namespace Envelope.View {

// title
var title_label = new Gtk.Label (_("Edit category"));
Granite.Widgets.Utils.apply_text_style_to_label (Granite.TextStyle.H3, title_label);
title_label.get_style_context ().add_class (Granite.STYLE_CLASS_H3_LABEL);
attach_next_to (title_label, null, Gtk.PositionType.TOP, 3, 1);

// category name text entry
Expand Down
2 changes: 1 addition & 1 deletion src/view/Sidebar.vala
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ namespace Envelope.View {
// style
var style_context = treeview.get_style_context ();
style_context.add_class (Gtk.STYLE_CLASS_SIDEBAR);
style_context.add_class (Granite.StyleClass.SOURCE_LIST);
style_context.add_class (Granite.STYLE_CLASS_SOURCE_LIST);

// selection
var selection = treeview.get_selection ();
Expand Down

0 comments on commit fef4db4

Please sign in to comment.