[maemo-commits] [maemo-commits] r8451 - in projects/haf/trunk/libosso-help: . debian src
From: www-data at stage.maemo.org www-data at stage.maemo.orgDate: Wed Nov 29 15:35:43 EET 2006
- Previous message: [maemo-commits] r8450 - projects/haf/tags/maemo-af-desktop
- Next message: [maemo-commits] r8452 - in projects/haf/trunk/osso-af-startup: debian top-scripts
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: pavelek Date: 2006-11-29 15:35:42 +0200 (Wed, 29 Nov 2006) New Revision: 8451 Modified: projects/haf/trunk/libosso-help/ChangeLog projects/haf/trunk/libosso-help/debian/changelog projects/haf/trunk/libosso-help/src/graphic.c Log: * Version 2.0.8 * src/graphics.c: changed the scaling of images in contents Modified: projects/haf/trunk/libosso-help/ChangeLog =================================================================== --- projects/haf/trunk/libosso-help/ChangeLog 2006-11-29 11:43:37 UTC (rev 8450) +++ projects/haf/trunk/libosso-help/ChangeLog 2006-11-29 13:35:42 UTC (rev 8451) @@ -1,3 +1,8 @@ +2006-11-29 Jakub Pavelek <jakub.pavelek at nokia.com> + + * Version 2.0.8 + * src/graphics.c: changed the scaling of images in contents + 2006-10-25 Jakub Pavelek <jakub.pavelek at nokia.com> * configure.ac: Generate also doc/Doxyfile Modified: projects/haf/trunk/libosso-help/debian/changelog =================================================================== --- projects/haf/trunk/libosso-help/debian/changelog 2006-11-29 11:43:37 UTC (rev 8450) +++ projects/haf/trunk/libosso-help/debian/changelog 2006-11-29 13:35:42 UTC (rev 8451) @@ -1,3 +1,9 @@ +libosso-help (2.0.8-1) unstable; urgency=low + + * Fixes: NB#47404 - zooming of images in help content + + -- Jakub Pavelek <jakub.pavelek at nokia.com> Wed, 29 Nov 2006 15:34:13 +0200 + libosso-help (2.0.7-1) unstable; urgency=low * Fixes NB#42988 Modified: projects/haf/trunk/libosso-help/src/graphic.c =================================================================== --- projects/haf/trunk/libosso-help/src/graphic.c 2006-11-29 11:43:37 UTC (rev 8450) +++ projects/haf/trunk/libosso-help/src/graphic.c 2006-11-29 13:35:42 UTC (rev 8451) @@ -34,7 +34,7 @@ * * This should be around the size of 'normal' Help text in browser. */ -#define NORMAL_HEIGHT 13 +#define FORCED_IMAGE_HEIGHT 26 gboolean dialog_mode; /*internal.h*/ /*---( HelpLib portion -- HTML conversion )---*/ @@ -186,31 +186,14 @@ } } - /* If we don't know the height, or it is low enough, - just pass on the picture. */ - if (h <= NORMAL_HEIGHT) { - snprintf( buf, bufsize, "<img src=\"file://%s\"/>", fname ); - } else { - /* TBD: This size reducement needs adjusting, based on needs - * of Help material. - * - * If <= 2*NORMAL_HEIGHT, reduce to normal height (maintaining - * aspect ratio). - * - * If higher, reduce to 2*NORMAL_HEIGHT (maintaining aspect ratio) - */ - if (h <= 2*NORMAL_HEIGHT) { - w /= ((float)h) / NORMAL_HEIGHT; - h= NORMAL_HEIGHT; - } else { - w /= ((float)h) / (2*NORMAL_HEIGHT); - h= 2*NORMAL_HEIGHT; - } - - snprintf( buf, bufsize, - "<img src=\"file://%s\" width=%d height=%d/>", - fname, w, h ); + /* Force image height to 26 pixels */ + if (h != FORCED_IMAGE_HEIGHT) { + w /= ((float)h) / (FORCED_IMAGE_HEIGHT); + h= FORCED_IMAGE_HEIGHT; } + snprintf( buf, bufsize, + "<img src=\"file://%s\" width=%d height=%d/>", + fname, w, h ); return TRUE; }
- Previous message: [maemo-commits] r8450 - projects/haf/tags/maemo-af-desktop
- Next message: [maemo-commits] r8452 - in projects/haf/trunk/osso-af-startup: debian top-scripts
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]