From: Jon A. Cruz Date: Thu, 31 Dec 2009 07:28:06 +0000 (-0800) Subject: Warning cleanup for char const* X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=863e29efafb46dd2d022f903bb53a86845179c8c;p=inkscape.git Warning cleanup for char const* --- diff --git a/src/sp-flowtext.cpp b/src/sp-flowtext.cpp index feb79cd9a..53bcd425d 100644 --- a/src/sp-flowtext.cpp +++ b/src/sp-flowtext.cpp @@ -375,15 +375,13 @@ static gchar *sp_flowtext_description(SPItem *item) Inkscape::Text::Layout const &layout = SP_FLOWTEXT(item)->layout; int const nChars = layout.iteratorToCharIndex(layout.end()); - char *trunc = ""; - if (layout.inputTruncated()) { - trunc = _(" [truncated]"); - } + char const *trunc = (layout.inputTruncated()) ? _(" [truncated]") : ""; - if (SP_FLOWTEXT(item)->has_internal_frame()) + if (SP_FLOWTEXT(item)->has_internal_frame()) { return g_strdup_printf(ngettext("Flowed text (%d character%s)", "Flowed text (%d characters%s)", nChars), nChars, trunc); - else + } else { return g_strdup_printf(ngettext("Linked flowed text (%d character%s)", "Linked flowed text (%d characters%s)", nChars), nChars, trunc); + } } static void sp_flowtext_snappoints(SPItem const *item, bool const target, SnapPointsWithType &p, Inkscape::SnapPreferences const */*snapprefs*/)