--- rxvt-unicode/src/command.C 2012/04/13 09:23:58 1.508 +++ rxvt-unicode/src/command.C 2012/05/25 08:27:47 1.510 @@ -3453,10 +3453,19 @@ if (!strcmp (str, "?")) { char str[256]; + int h_scale = 0, v_scale = 0; + int h_align = 0, v_align = 0; + if (image_vec.size () > 0) + { + h_scale = image_vec[0].h_scale; + v_scale = image_vec[0].v_scale; + h_align = image_vec[0].h_align; + v_align = image_vec[0].v_align; + } sprintf (str, "[%dx%d+%d+%d]", - min (h_scale, 32767), min (v_scale, 32767), - min (h_align, 32767), min (v_align, 32767)); + h_scale, v_scale, + h_align, v_align); process_xterm_seq (XTerm_title, str, CHAR_ST); } else @@ -3465,13 +3474,23 @@ if (*str != ';') { - if (bg_set_file (str)) /* change pixmap */ + if (image_vec.size () > 0 + && image_vec[0].set_file_geometry (str)) changed = true; + else + { + rxvt_image *image = new_image (); + if (!image->set_file_geometry (str)) + image_vec.pop_back (); + else + changed = true; + } } else { str++; - if (bg_set_geometry (str, true)) + if (image_vec.size () > 0 + && image_vec[0].set_geometry (str, true)) changed = true; }