aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-week-view-main-item.c
diff options
context:
space:
mode:
Diffstat (limited to 'calendar/gui/e-week-view-main-item.c')
-rw-r--r--calendar/gui/e-week-view-main-item.c33
1 files changed, 26 insertions, 7 deletions
diff --git a/calendar/gui/e-week-view-main-item.c b/calendar/gui/e-week-view-main-item.c
index d30404305d..10990324ff 100644
--- a/calendar/gui/e-week-view-main-item.c
+++ b/calendar/gui/e-week-view-main-item.c
@@ -315,22 +315,41 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
max_width = width - 4;
format_string = NULL;
if (show_day_name) {
- if (week_view->max_abbr_day_width +
- week_view->digit_width * 2 + week_view->space_width * 2
+ if (week_view->max_day_width + week_view->digit_width * 2
+ + week_view->space_width * 2
+ week_view->month_widths[month - 1] < max_width)
- format_string = "%a %d %B";
+ /* strftime format %A = full weekday name, %d = day of
+ month, %B = full month name. You can change the
+ order but don't change the specifiers or add
+ anything. */
+ format_string = _("%A %d %B");
+ else if (week_view->max_abbr_day_width
+ + week_view->digit_width * 2
+ + week_view->space_width * 2
+ + week_view->abbr_month_widths[month - 1] < max_width)
+ /* strftime format %a = abbreviated weekday name,
+ %d = day of month, %b = abbreviated month name.
+ You can change the order but don't change the
+ specifiers or add anything. */
+ format_string = _("%a %d %b");
}
if (!format_string && show_month_name) {
if (week_view->digit_width * 2 + week_view->space_width
+ week_view->month_widths[month - 1] < max_width)
- format_string = "%d %B";
+ /* strftime format %d = day of month, %B = full
+ month name. You can change the order but don't
+ change the specifiers or add anything. */
+ format_string = _("%d %B");
else if (week_view->digit_width * 2 + week_view->space_width
+ week_view->abbr_month_widths[month - 1] < max_width)
- format_string = "%d %b";
+ /* strftime format %d = day of month, %b = abbreviated
+ month name. You can change the order but don't
+ change the specifiers or add anything. */
+ format_string = _("%d %b");
}
- g_date_strftime (buffer, 128, format_string ? format_string : "%d",
- date);
+ g_date_strftime (buffer, sizeof (buffer),
+ format_string ? format_string : "%d", date);
date_width = gdk_string_width (font, buffer);
date_x = x + width - date_width - E_WEEK_VIEW_DATE_R_PAD;
date_x = MAX (date_x, x + 1);
sertions'>+2 * Update to 3.2.16bdrewery2014-07-253-3/+14 * - Replace security/gnutls with security/gnutls3 and update to 3.2.15tijl2014-07-238-916/+383 * Add DOCS to OPTIONS_DEFINE to ports that check for PORT_OPTIONS:MDOCS.adamw2014-07-161-1/+1 * Patch CVE-2014-3466 to prevent memory corruption due to server hello parsing.cy2014-06-052-1/+12 * - New LIB_DEPENDS syntax.tijl2014-05-012-15/+14 * - Add fixes for:bdrewery2014-03-052-1/+104 * Add an additional mirror to MASTER_SITES.novel2014-01-221-1/+2 * Fix properties on pkg-plistbapt2014-01-221-1/+0 * Fix build with perl 5.18.novel2014-01-131-0/+612 * security/gnutls: Fix hardcoded perl pathsmarino2014-01-111-1/+4 * - Fix possbile DoS in TLS record decoding [1]novel2014-01-083-6/+18 * - Support stagedirnovel2014-01-064-682/+682 * - Chase security/libtasn1 updatenovel2013-11-031-1/+1 * Add NO_STAGE all over the place in preparation for the staging support (cat: ...bapt2013-09-211-0/+1 * - Remove MAKE_JOBS_SAFE variableak2013-08-151-1/+0 * - Convert USE_ICONV=yes to USES=iconvmva2013-04-281-3/+2 * - Convert USE_GETTEXT to USES (part 4)ak2013-04-261-1/+1 * Finish converting the whole ports tree to USES=pkgconfigbapt2013-04-231-6/+2 * - Add UPDATING entry for libtasn1 updatenovel2013-02-071-0/+1 * Update to 2.12.23.novel2013-02-065-45/+22 * - Drop automatic dependency detection [1]novel2012-08-151-9/+13 * Respect NOPORTEXAMPLES.novel2012-04-102-25/+5 * Update to 2.12.18. This update includes a dirty hack to prevent sharednovel2012-03-254-3/+33 * Update to 2.12.16.novel2012-01-122-3/+3 * - Remove WITH_FBSD10_FIX, is no longer neededmiwi2011-11-091-1/+0 * Update to 2.12.14.novel2011-11-092-3/+3 * - Fix build on FreeBSD 10miwi2011-10-291-0/+1 * Update to 2.12.12.novel2011-10-242-3/+3 * - Add LDFLAGS to CONFIGURE_ENV and MAKE_ENV (as it was done with LDFLAGS)amdmi32011-09-241-1/+1 * Update to 2.12.11.novel2011-09-192-3/+3 * Update to 2.12.10.novel2011-09-162-3/+3 * Update to 2.12.9.novel2011-08-223-21/+5 * - Switch to nettle as crypto library as it's primary librarynovel2011-07-141-3/+3 * - Chase the libgcrypt shared lib versionswills2011-07-031-1/+2 * Update to 2.12.7.novel2011-06-233-4/+6 * - Bump PORTREVISION for the .pc fixpav2011-06-071-0/+1 * Proper fix for gnutls.pc generation by ripping out 'zlib' partnovel2011-06-062-3/+16 * Fix gnutls.pc file by stripping 'zlib' from Requires.private.novel2011-06-061-0/+3