[gnote] Remove boost::format from print notes
- From: Aurimas Černius <aurimasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnote] Remove boost::format from print notes
- Date: Fri, 13 Jan 2017 20:54:42 +0000 (UTC)
commit d8a54430e02556b982483bf7c2aa682cea7187d0
Author: Aurimas Černius <aurisc4 gmail com>
Date: Fri Jan 13 22:28:05 2017 +0200
Remove boost::format from print notes
src/addins/printnotes/printnotes.desktop.in.in | 2 +-
src/addins/printnotes/printnotesnoteaddin.cpp | 10 ++++------
2 files changed, 5 insertions(+), 7 deletions(-)
---
diff --git a/src/addins/printnotes/printnotes.desktop.in.in b/src/addins/printnotes/printnotes.desktop.in.in
index cd5bf1d..60eeb30 100644
--- a/src/addins/printnotes/printnotes.desktop.in.in
+++ b/src/addins/printnotes/printnotes.desktop.in.in
@@ -4,7 +4,7 @@ _Name=Printing Support
_Description=Allows you to print a note.
_Authors=Hubert Figuiere and the Tomboy Project
Category=DesktopIntegration
-Version=0.8
+Version=0.9
DefaultEnabled=true
Module=libprintnotes
LibgnoteRelease=@LIBGNOTE_RELEASE@
diff --git a/src/addins/printnotes/printnotesnoteaddin.cpp b/src/addins/printnotes/printnotesnoteaddin.cpp
index 624adfe..d2bb35f 100644
--- a/src/addins/printnotes/printnotesnoteaddin.cpp
+++ b/src/addins/printnotes/printnotesnoteaddin.cpp
@@ -1,7 +1,7 @@
/*
* gnote
*
- * Copyright (C) 2010-2013,2015-2016 Aurimas Cernius
+ * Copyright (C) 2010-2013,2015-2017 Aurimas Cernius
* Copyright (C) 2009 Hubert Figuiere
*
* This program is free software: you can redistribute it and/or modify
@@ -20,8 +20,6 @@
-#include <boost/format.hpp>
-
#include <glibmm/i18n.h>
#include <glibmm/miscutils.h>
#include <gtkmm/image.h>
@@ -276,9 +274,9 @@ namespace printnotes {
layout->set_font_description(font_desc);
layout->set_width(pango_units_from_double((int)context->get_width()));
- // %1% is the page number, %2% is the total number of pages
- std::string footer_left = str(boost::format(_("Page %1% of %2%"))
- % page_number % total_pages);
+ // %1 is the page number, %2 is the total number of pages
+ Glib::ustring footer_left = Glib::ustring::compose(_("Page %1 of %2"),
+ page_number, total_pages);
layout->set_alignment(Pango::ALIGN_LEFT);
layout->set_text (footer_left);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]