It appears as [%zoom%] in fullscreen info string.
It is now displayed by default.
void set_default_fullscreen_info(ConfOptions *options)
{
if (options->fullscreen.info) g_free(options->fullscreen.info);
- options->fullscreen.info = g_strdup("%collection%(%number%/%total%) <b>%name%</b>\n"
- "%res%|%date%|%size%\n"
- "%fAperture%|%fShutterSpeed%|%fISOSpeedRating%|%fFocalLength%|%fExposureBias%\n"
- "%fCamera%|%fFlash%");
+ options->fullscreen.info = g_strdup(DEFAULT_OVERLAY_INFO);
}
static void clear_mouse_cursor(GtkWidget *widget, gint state)
pos = start-new->str;
data = g_strdup(g_hash_table_lookup(vars, name));
+ if (data && strcmp(name, "zoom") == 0) imd->overlay_show_zoom = TRUE;
if (!data && exif)
data = exif_get_data_as_text(exif, name);
if (data && *data && limit > 0 && strlen(data) > limit + 3)
g_hash_table_insert(vars, "name", g_strdup(name_escaped));
g_hash_table_insert(vars, "date", g_strdup(text_from_time(imd->mtime)));
g_hash_table_insert(vars, "size", g_strdup(size));
-
+ g_hash_table_insert(vars, "zoom", image_zoom_get_as_text(imd));
+
if (!name_escaped)
{
text = g_strdup_printf(_("Untitled"));
{
OverlayStateData *osd = data;
+ osd->imd->overlay_show_zoom = FALSE;
+
if (osd->show_info)
{
if (osd->changed_states & IMAGE_STATE_IMAGE)
#include "collect.h"
#include "color-man.h"
#include "exif.h"
+#include "image-overlay.h"
#include "layout.h"
#include "layout_image.h"
#include "pixbuf-renderer.h"
ImageWindow *imd = data;
if (imd->title_show_zoom) image_update_title(imd);
+ if (imd->overlay_show_zoom) image_osd_update(imd);
+
image_update_util(imd);
}
{
r = 1.0 / scale;
}
- approx = " ~";
+ approx = "~";
}
if (rint(l) != l) pl = 1;
#define IMAGE_LOADER_IDLE_READ_LOOP_COUNT_MIN 1
#define IMAGE_LOADER_IDLE_READ_LOOP_COUNT_MAX 16
+
+#define DEFAULT_OVERLAY_INFO "%collection%(%number%/%total%) [%zoom%] <b>%name%</b>\n" \
+ "%res%|%date%|%size%\n" \
+ "%fAperture%|%fShutterSpeed%|%fISOSpeedRating%|%fFocalLength%|%fExposureBias%\n" \
+ "%fCamera%|%fFlash%" \
+
#if 1 /* set to 0 to disable debugging code and related options */
# ifndef DEBUG
# define DEBUG 1
gint delay_flip;
gint orientation;
gint desaturate;
+
+ gint overlay_show_zoom; /* set to true if overlay is showing zoom ratio */
};
#define FILEDATA_MARKS_SIZE 6