diff -rc gv-3.7.4/configure gv-xft-3.7.4/configure *** gv-3.7.4/configure 2013-03-17 12:20:09.000000000 +0100 --- gv-xft-3.7.4/configure 2014-05-02 14:22:59.879439785 +0200 *************** *** 13604,13616 **** true fi ! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawInitializeWidgetSet in -lXaw3d" >&5 ! $as_echo_n "checking for XawInitializeWidgetSet in -lXaw3d... " >&6; } if test "${ac_cv_lib_Xaw3d_XawInitializeWidgetSet+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS ! LIBS="-lXaw3d $X_LIBS $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ --- 13604,13616 ---- true fi ! { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawInitializeWidgetSet in -l$XAW3DLIB" >&5 ! $as_echo_n "checking for XawInitializeWidgetSet in -l$XAW3DLIB ... " >&6; } if test "${ac_cv_lib_Xaw3d_XawInitializeWidgetSet+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS ! LIBS="-l$XAW3DLIB $X_LIBS $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ *************** *** 13645,13651 **** #define HAVE_LIBXAW3D 1 _ACEOF ! LIBS="-lXaw3d $LIBS" else as_fn_error "Unable to find a valid Xaw3d library. Please install it and rerun configure." "$LINENO" 5 --- 13645,13651 ---- #define HAVE_LIBXAW3D 1 _ACEOF ! LIBS="-l$XAW3DLIB $LIBS" else as_fn_error "Unable to find a valid Xaw3d library. Please install it and rerun configure." "$LINENO" 5 Seulement dans gv-xft-3.7.4: debian diff -rc gv-3.7.4/src/FileSel.c gv-xft-3.7.4/src/FileSel.c *** gv-3.7.4/src/FileSel.c 2012-04-01 16:43:24.000000000 +0200 --- gv-xft-3.7.4/src/FileSel.c 2014-05-02 18:09:53.530875424 +0200 *************** *** 1853,1859 **** SET_Arg(XtNallowMarks, False); SET_Arg(XtNjustify, XtJustifyLeft); *listP = ADD_Widget_Arg("list",vlistWidgetClass,*aaaP); - ENDMESSAGE(CreateList) } --- 1853,1858 ---- diff -rc gv-3.7.4/src/main.c gv-xft-3.7.4/src/main.c *** gv-3.7.4/src/main.c 2012-04-01 16:43:24.000000000 +0200 --- gv-xft-3.7.4/src/main.c 2014-05-02 20:26:04.052136882 +0200 *************** *** 62,67 **** --- 62,70 ---- #include INC_XAW(Scrollbar.h) #include INC_XAW(XawInit.h) #include INC_XMU(Editres.h) + #ifdef HAVE_XAW3DXFT + #include + #endif #ifdef HAVE_LIBXINERAMA #include INC_EXT(Xinerama.h) #endif *************** *** 323,328 **** --- 326,348 ---- int main(int argc, char *argv[]) { + #ifdef HAVE_XAW3DXFT + XftInitFtLibrary(); + Xaw3dXftSetDefaultFontName("Liberation-10"); + Xaw3dXftSetHilitColor("#332211"); + Xaw3dXftSetInsensitiveTwist("#a00000"); + Xaw3dXftMenuSpacing = 0; + Xaw3dXftEncoding = -1; + Xaw3dXftStringHilight = 0; + Xaw3dXftStringUsePixmap = 0; + Xaw3dXftNoHilitReverse = 1; + Xaw3dXftButtonInverse = 0; + Xaw3dXftButtonDashed = 1; + Xaw3dXftShowTips = 1; + Xaw3dXftTextBgHilight = 1; + Xaw3dXftTextBgHilightColor = 0x332211; + #endif + MAINBEGINMESSAGE(main) gv_safe_gs_workdir = GV_LIBDIR "/safe-gs-workdir"; gv_safe_gs_tempdir = 0; Seulement dans gv-xft-3.7.4/src: main.c~ diff -rc gv-3.7.4/src/misc_private.c gv-xft-3.7.4/src/misc_private.c *** gv-3.7.4/src/misc_private.c 2012-03-29 18:03:49.000000000 +0200 --- gv-xft-3.7.4/src/misc_private.c 2014-05-02 15:52:46.514612158 +0200 *************** *** 44,49 **** --- 44,52 ---- #include INC_XAW(Cardinals.h) #include INC_X11(IntrinsicP.h) #include INC_XAW(LabelP.h) + #ifdef HAVE_XAW3DXFT + #include + #endif #include "GhostviewP.h" #include "types.h" *************** *** 111,119 **** --- 114,127 ---- #ifdef HAVE_XAW3D_INTERNATIONAL if( vw->simple.international == True ) { + #ifdef HAVE_XAW3DXFT + Xaw3dXftDrawString(widget, Xaw3dXftDefaultFont, + x, y, text, (int)(strlen(text))); + #else XmbDrawString(XtDisplay(widget), XtWindow(widget), w->label.fontset, w->label.normal_GC, x, y, text, (int)(strlen(text))); + #endif } else { #endif if (w->label.encoding) { *************** *** 121,129 **** --- 129,142 ---- w->label.normal_GC, x, y,(XChar2b*)text, (int)(strlen(text))); } else { + #ifdef HAVE_XAW3DXFT + Xaw3dXftDrawString(widget, Xaw3dXftDefaultFont, + x, y, text, (int)(strlen(text))); + #else XDrawString(XtDisplay(widget), XtWindow(widget), w->label.normal_GC, x, y, text, (int)(strlen(text))); + #endif } #ifdef HAVE_XAW3D_INTERNATIONAL } diff -rc gv-3.7.4/src/paths.h gv-xft-3.7.4/src/paths.h *** gv-3.7.4/src/paths.h 2012-04-01 16:43:24.000000000 +0200 --- gv-xft-3.7.4/src/paths.h 2014-05-02 12:19:02.351201784 +0200 *************** *** 37,48 **** --- 37,56 ---- #if HAVE_GCC_VERSION(2,95) #define INC_X11(aaa) #define INC_XMU(aaa) + #ifdef HAVE_XAW3DXFT + #define INC_XAW(aaa) + #else #define INC_XAW(aaa) + #endif #define INC_EXT(aaa) #else #define INC_X11(aaa) #define INC_XMU(aaa) + #ifdef HAVE_XAW3DXFT + #define INC_XAW(aaa) + #else #define INC_XAW(aaa) + #endif #define INC_EXT(aaa) #endif diff -rc gv-3.7.4/src/Vlist.c gv-xft-3.7.4/src/Vlist.c *** gv-3.7.4/src/Vlist.c 2012-04-01 16:43:24.000000000 +0200 --- gv-xft-3.7.4/src/Vlist.c 2014-05-02 18:31:38.121917171 +0200 *************** *** 49,55 **** #include "VlistP.h" #include "Frame.h" #include INC_XMU(Converters.h) ! #define VLIST_MARK_LEFT_INDENT 4 #define VLIST_MARK_LABEL_INTERNAL_WIDTH 11 #define VLIST_MARK_LABEL_INDENT 4 --- 49,57 ---- #include "VlistP.h" #include "Frame.h" #include INC_XMU(Converters.h) ! #ifdef HAVE_XAW3DXFT ! #include ! #endif #define VLIST_MARK_LEFT_INDENT 4 #define VLIST_MARK_LABEL_INTERNAL_WIDTH 11 #define VLIST_MARK_LABEL_INDENT 4 *************** *** 214,230 **** --- 216,243 ---- values.graphics_exposures = False; vw->vlist.background_GC = XtGetGC((Widget)vw,(unsigned) GCForeground | GCGraphicsExposures,&values); + Dimension merde; /* TODO: check if this works here in international mode, or if it has * to be moved to Realize... */ #ifdef HAVE_XAW3D_INTERNATIONAL if( vw->simple.international == True ) { + #ifdef HAVE_XAW3DXFT + vw->vlist.yofs = Xaw3dXftDefaultFont->ascent + 1; + vw->vlist.ydelta = Xaw3dXftDefaultFont->ascent + Xaw3dXftDefaultFont->descent; + #else XFontSetExtents *ext = XExtentsOfFontSet(vw->label.fontset); vw->vlist.yofs = (ext->max_ink_extent.y<0)?-ext->max_ink_extent.y:ext->max_ink_extent.y; vw->vlist.ydelta = ext->max_ink_extent.height; + #endif } else { #endif + #ifdef HAVE_XAW3DXFT + vw->vlist.yofs = Xaw3dXftDefaultFont->ascent + 1; + vw->vlist.ydelta = Xaw3dXftDefaultFont->ascent + Xaw3dXftDefaultFont->descent; + #else vw->vlist.yofs = vw->label.font->max_bounds.ascent; vw->vlist.ydelta = vw->label.font->max_bounds.ascent + vw->label.font->max_bounds.descent; + #endif #ifdef HAVE_XAW3D_INTERNATIONAL } #endif *************** *** 339,353 **** --- 352,380 ---- len = strlen(s); #ifdef HAVE_XAW3D_INTERNATIONAL if( vw->simple.international == True ) + #ifdef HAVE_XAW3DXFT + Xaw3dXftDrawString(w, Xaw3dXftDefaultFont, + vw->label.label_x, + vw->label.label_y + yofs + entry*ydelta, + s, len); + #else XmbDrawString(XtDisplay(w), XtWindow(w), vw->label.fontset, vw->label.normal_GC, vw->label.label_x, vw->label.label_y + yofs + entry*ydelta, s, len); + #endif else #endif + #ifdef HAVE_XAW3DXFT + Xaw3dXftDrawString(w, Xaw3dXftDefaultFont, + vw->label.label_x, + vw->label.label_y + yofs + entry*ydelta, + s, len); + #else XDrawString(XtDisplay(w), XtWindow(w), vw->label.normal_GC, vw->label.label_x, vw->label.label_y + yofs + entry*ydelta, s, len); + #endif } ENDMESSAGE1(PaintEntryString) } *************** *** 404,416 **** if (region == NULL || XRectInRegion(region,x,y,width,height) != RectangleOut) { if (erase) { INFMESSAGE(clearing entry) ! XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w),vw->vlist.background_GC,x,y,width,height); } else { INFMESSAGE(drawing entry) XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w),gc,x,y,width,height); FrameDrawFrame(w,x,y,width,height,ss,sw, vw->threeD.top_shadow_GC, vw->threeD.bot_shadow_GC); } ret=1; } --- 431,453 ---- if (region == NULL || XRectInRegion(region,x,y,width,height) != RectangleOut) { if (erase) { INFMESSAGE(clearing entry) ! #ifndef HAVE_XAW3DXFT ! XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w),vw->vlist.background_GC,x,y,width,height); ! #else ! XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w),vw->vlist.background_GC,x,y-1,width,height+2); ! #endif } else { INFMESSAGE(drawing entry) + #ifndef HAVE_XAW3DXFT XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w),gc,x,y,width,height); FrameDrawFrame(w,x,y,width,height,ss,sw, vw->threeD.top_shadow_GC, vw->threeD.bot_shadow_GC); + #else + FrameDrawFrame(w,x,y-1,width,height+2,ss,sw, + vw->threeD.top_shadow_GC, + vw->threeD.bot_shadow_GC); + #endif } ret=1; } *************** *** 491,505 **** if (region == NULL || XRectInRegion(region,x,y,width,height) != RectangleOut) { if (paint) { INFMESSAGE(drawing mark) XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w),vw->vlist.mark_background_GC,x,y,width,height); FrameDrawFrame(w,x,y,width,height,ss,vw->vlist.mark_shadow_width, vw->threeD.top_shadow_GC, vw->threeD.bot_shadow_GC); } else { INFMESSAGE(clearing mark) XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w), (entry == vw->vlist.highlighted) ? vw->vlist.highlighted_background_GC : vw->vlist.background_GC, ! x,y,width,height); } } } --- 528,552 ---- if (region == NULL || XRectInRegion(region,x,y,width,height) != RectangleOut) { if (paint) { INFMESSAGE(drawing mark) + #ifndef HAVE_XAW3DXFT XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w),vw->vlist.mark_background_GC,x,y,width,height); FrameDrawFrame(w,x,y,width,height,ss,vw->vlist.mark_shadow_width, vw->threeD.top_shadow_GC, vw->threeD.bot_shadow_GC); + #else + FrameDrawFrame(w,x,y-1,width,height+2,ss,vw->vlist.mark_shadow_width, + vw->threeD.top_shadow_GC, + vw->threeD.bot_shadow_GC); + #endif } else { INFMESSAGE(clearing mark) XFillRectangle(XtDisplayOfObject(w), XtWindowOfObject(w), (entry == vw->vlist.highlighted) ? vw->vlist.highlighted_background_GC : vw->vlist.background_GC, ! #ifndef HAVE_XAW3DXFT ! x,y,width,height); ! #else ! x,y-1,width,height+2); ! #endif } } } *************** *** 589,600 **** --- 636,657 ---- if (y + (vw->vlist.ydelta - vw->vlist.yofs) >= rectangle.y) { #ifdef HAVE_XAW3D_INTERNATIONAL if( vw->simple.international == True ) + #ifdef HAVE_XAW3DXFT + Xaw3dXftDrawString(w, Xaw3dXftDefaultFont, + vw->label.label_x, y, s, len); + #else XmbDrawString(XtDisplay(w), XtWindow(w), vw->label.fontset, vw->label.normal_GC, vw->label.label_x, y, s, len); + #endif else #endif + #ifdef HAVE_XAW3DXFT + Xaw3dXftDrawString(w, Xaw3dXftDefaultFont, + vw->label.label_x, y, s, len); + #else XDrawString(XtDisplay(w), XtWindow(w), vw->label.normal_GC, vw->label.label_x, y, s, len); + #endif } if (nl) s = nl + 1; *************** *** 955,961 **** int entriesvisible = -1; if (vw->vlist.ydelta > 0) { ! entriesvisible = height/vw->vlist.ydelta; } #if 0 printf("fitting %d entries of height %d in %d", --- 1012,1018 ---- int entriesvisible = -1; if (vw->vlist.ydelta > 0) { ! entriesvisible = height/(vw->vlist.ydelta); } #if 0 printf("fitting %d entries of height %d in %d", *************** *** 968,974 **** --- 1025,1036 ---- entriesvisible,(int)(vw->vlist.entries), entriesvisible/(float)(vw->vlist.entries)); #endif + #ifdef HAVE_XAW3DXFT + percent = 0.8 * entriesvisible/(float)(vw->vlist.entries); + #else percent = entriesvisible/(float)(vw->vlist.entries); + #endif + if (percent>1.0) percent = 1.0; INFMESSAGE(VlistVisibleLength) IIMESSAGE(entriesvisible,vw->vlist.entries) FMESSAGE(percent)