tint2conf enabled by default, and switch ELLIPSIZE_END to ELLIPSIZE_MIDDLE
git-svn-id: http://tint2.googlecode.com/svn/trunk@433 121b4492-b84c-0410-8b4c-0d4edfb3f3cc
This commit is contained in:
@@ -31,12 +31,12 @@ AM_CONDITIONAL([INSTALL_EXAMPLES], [test x$examples = xtrue])
|
|||||||
|
|
||||||
# tint2conf
|
# tint2conf
|
||||||
AC_ARG_ENABLE([tint2conf],
|
AC_ARG_ENABLE([tint2conf],
|
||||||
[AS_HELP_STRING([--enable-tint2conf], [Enable tint2conf build, a GTK+2 theme switcher for tint2])],
|
[AS_HELP_STRING([--disable-tint2conf], [Disable tint2conf build, a GTK+2 theme switcher for tint2])],
|
||||||
[case "${enableval}" in
|
[case "${enableval}" in
|
||||||
yes) tint2conf=true ;;
|
yes) tint2conf=true ;;
|
||||||
no) tint2conf=false ;;
|
no) tint2conf=false ;;
|
||||||
*) AC_MSG_ERROR([bad value ${enableval} for --enable-tint2conf]) ;;
|
*) AC_MSG_ERROR([bad value ${enableval} for --disable-tint2conf]) ;;
|
||||||
esac],[tint2conf=false])
|
esac],[tint2conf=true])
|
||||||
AM_CONDITIONAL([ENABLE_TINT2CONF], [test x$tint2conf = xtrue])
|
AM_CONDITIONAL([ENABLE_TINT2CONF], [test x$tint2conf = xtrue])
|
||||||
#
|
#
|
||||||
|
|
||||||
|
|||||||
@@ -56,7 +56,6 @@ static Pixmap render_background;
|
|||||||
|
|
||||||
void default_systray()
|
void default_systray()
|
||||||
{
|
{
|
||||||
printf("*** default_systray()\n");
|
|
||||||
memset(&systray, 0, sizeof(Systraybar));
|
memset(&systray, 0, sizeof(Systraybar));
|
||||||
render_background = 0;
|
render_background = 0;
|
||||||
systray.alpha = 100;
|
systray.alpha = 100;
|
||||||
|
|||||||
@@ -353,7 +353,8 @@ void draw_task (void *obj, cairo_t *c)
|
|||||||
/* Drawing width and Cut text */
|
/* Drawing width and Cut text */
|
||||||
// pango use U+22EF or U+2026
|
// pango use U+22EF or U+2026
|
||||||
pango_layout_set_width (layout, ((Taskbar*)tsk->area.parent)->text_width * PANGO_SCALE);
|
pango_layout_set_width (layout, ((Taskbar*)tsk->area.parent)->text_width * PANGO_SCALE);
|
||||||
pango_layout_set_ellipsize (layout, PANGO_ELLIPSIZE_END);
|
pango_layout_set_ellipsize (layout, PANGO_ELLIPSIZE_MIDDLE);
|
||||||
|
//pango_layout_set_wrap(layout, PANGO_WRAP_CHAR);
|
||||||
|
|
||||||
/* Center text */
|
/* Center text */
|
||||||
if (panel->g_task.centered) pango_layout_set_alignment (layout, PANGO_ALIGN_CENTER);
|
if (panel->g_task.centered) pango_layout_set_alignment (layout, PANGO_ALIGN_CENTER);
|
||||||
|
|||||||
@@ -231,7 +231,7 @@ void tooltip_update()
|
|||||||
pango_layout_get_pixel_extents(layout, &r1, &r2);
|
pango_layout_get_pixel_extents(layout, &r1, &r2);
|
||||||
pango_layout_set_width(layout, width*PANGO_SCALE);
|
pango_layout_set_width(layout, width*PANGO_SCALE);
|
||||||
pango_layout_set_height(layout, height*PANGO_SCALE);
|
pango_layout_set_height(layout, height*PANGO_SCALE);
|
||||||
pango_layout_set_ellipsize(layout, PANGO_ELLIPSIZE_END);
|
pango_layout_set_ellipsize(layout, PANGO_ELLIPSIZE_MIDDLE);
|
||||||
// I do not know why this is the right way, but with the below cairo_move_to it seems to be centered (horiz. and vert.)
|
// I do not know why this is the right way, but with the below cairo_move_to it seems to be centered (horiz. and vert.)
|
||||||
cairo_move_to(c, -r1.x/2+g_tooltip.bg->border.width+g_tooltip.paddingx, -r1.y/2+g_tooltip.bg->border.width+g_tooltip.paddingy);
|
cairo_move_to(c, -r1.x/2+g_tooltip.bg->border.width+g_tooltip.paddingx, -r1.y/2+g_tooltip.bg->border.width+g_tooltip.paddingy);
|
||||||
pango_cairo_show_layout (c, layout);
|
pango_cairo_show_layout (c, layout);
|
||||||
|
|||||||
Reference in New Issue
Block a user