Widened pop-up prompt window (to avoid wordwrap/overlap issue in some locales).

SF.net bug #2834461
This commit is contained in:
William Kendrick 2009-08-09 16:35:28 +00:00
parent 965a5bbf59
commit 7d45258c8c
3 changed files with 38 additions and 32 deletions

View file

@ -19,6 +19,10 @@ $Id$
-------------------
* Starter images can be in SVG format.
* Widened dialog windows, to help avoid word-wrap and overlap problems
with some prompts, in some locales.
(SF.net bug #2834461)
* Localization Updates:
---------------------
* Chinese (Traditional) translation

View file

@ -22,7 +22,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
(See COPYING.txt)
June 14, 2002 - June 13, 2009
June 14, 2002 - August 9, 2009
$Id$
*/
@ -11628,6 +11628,9 @@ static int do_prompt_image_flash(const char *const text,
(text, btn_yes, btn_no, img1, img2, img3, animate, SND_NONE, ox, oy));
}
#define PROMPT_LEFT 96
#define PROMPT_W 440
static int do_prompt_image_flash_snd(const char *const text,
const char *const btn_yes,
const char *const btn_no,
@ -11655,7 +11658,6 @@ static int do_prompt_image_flash_snd(const char *const text,
hide_blinking_cursor();
/* Admittedly stupid way of determining which keys can be used for
positive and negative responses in dialogs (e.g., [Y] (for 'yes') in English) */
keystr = textdir(gettext("Yes"));
@ -11698,12 +11700,12 @@ static int do_prompt_image_flash_snd(const char *const text,
oox = ox - w;
ooy = oy - w;
nx = 160 + 96 - w + PROMPTOFFSETX;
nx = PROMPT_LEFT + 96 - w + PROMPTOFFSETX;
ny = 94 + 96 - w + PROMPTOFFSETY;
dest.x = ((nx * w) + (oox * (96 - w))) / 96;
dest.y = ((ny * w) + (ooy * (96 - w))) / 96;
dest.w = (320 - 96 * 2) + w * 2;
dest.w = (PROMPT_W - 96 * 2) + w * 2;
dest.h = w * 2;
SDL_FillRect(screen, &dest, SDL_MapRGB(screen->format, 224 - w, 224 - w, 244 -w));
@ -11723,7 +11725,7 @@ static int do_prompt_image_flash_snd(const char *const text,
#ifndef NO_PROMPT_SHADOWS
alpha_surf = SDL_CreateRGBSurface(SDL_SWSURFACE | SDL_SRCALPHA,
(320 - 96 * 2) + (w - 4) * 2,
(PROMPT_W - 96 * 2) + (w - 4) * 2,
(w - 4) * 2,
screen->format->BitsPerPixel,
screen->format->Rmask,
@ -11738,9 +11740,9 @@ static int do_prompt_image_flash_snd(const char *const text,
for (i = 8; i > 0; i = i - 2)
{
dest.x = 160 + 96 - (w - 4) + i + PROMPTOFFSETX;
dest.x = PROMPT_LEFT + 96 - (w - 4) + i + PROMPTOFFSETX;
dest.y = 94 + 96 - (w - 4) + i + PROMPTOFFSETY;
dest.w = (320 - 96 * 2) + (w - 4) * 2;
dest.w = (PROMPT_W - 96 * 2) + (w - 4) * 2;
dest.h = (w - 4) * 2;
SDL_BlitSurface(alpha_surf, NULL, screen, &dest);
@ -11753,9 +11755,9 @@ static int do_prompt_image_flash_snd(const char *const text,
w = w - 6;
dest.x = 160 + 96 - w + PROMPTOFFSETX;
dest.x = PROMPT_LEFT + 96 - w + PROMPTOFFSETX;
dest.y = 94 + 96 - w + PROMPTOFFSETY;
dest.w = (320 - 96 * 2) + w * 2;
dest.w = (PROMPT_W - 96 * 2) + w * 2;
dest.h = w * 2;
SDL_FillRect(screen, &dest, SDL_MapRGB(screen->format, 255, 255, 255));
@ -11803,19 +11805,19 @@ static int do_prompt_image_flash_snd(const char *const text,
if (need_right_to_left == 0)
{
txt_left = 166 + PROMPTOFFSETX;
txt_right = 475 + PROMPTOFFSETX - offset;
img_left = 475 + PROMPTOFFSETX - max_img_w - 4;
btn_left = 166 + PROMPTOFFSETX;
txt_left = (PROMPT_LEFT + 6) + PROMPTOFFSETX;
txt_right = (PROMPT_LEFT + PROMPT_W - 5) + PROMPTOFFSETX - offset;
img_left = (PROMPT_LEFT + PROMPT_W - 5) + PROMPTOFFSETX - max_img_w - 4;
btn_left = (PROMPT_LEFT + 6) + PROMPTOFFSETX;
txt_btn_left = txt_left + img_yes->w + 4;
txt_btn_right = txt_right;
}
else
{
txt_left = 166 + PROMPTOFFSETX + offset;
txt_right = 457 + PROMPTOFFSETX;
img_left = 166 + PROMPTOFFSETX + 4;
btn_left = 475 + PROMPTOFFSETX - img_yes->w - 4;
txt_left = (PROMPT_LEFT + 6) + PROMPTOFFSETX + offset;
txt_right = (PROMPT_LEFT + PROMPT_W - 5) + PROMPTOFFSETX;
img_left = (PROMPT_LEFT + 6) + PROMPTOFFSETX + 4;
btn_left = (PROMPT_LEFT + PROMPT_W - 5) + PROMPTOFFSETX - img_yes->w - 4;
txt_btn_left = txt_left;
txt_btn_right = btn_left;
}
@ -18847,13 +18849,13 @@ int do_color_picker(void)
oox = ox - w;
ooy = oy - w;
nx = 160 + 96 - w + PROMPTOFFSETX;
nx = PROMPT_LEFT + 96 - w + PROMPTOFFSETX;
ny = 94 + 96 - w + PROMPTOFFSETY;
dest.x = ((nx * w) + (oox * (128 - w))) / 128;
dest.y = ((ny * w) + (ooy * (128 - w))) / 128;
dest.w = (320 - 96 * 2) + w * 2;
dest.w = (PROMPT_W - 96 * 2) + w * 2;
dest.h = w * 2;
SDL_FillRect(screen, &dest, SDL_MapRGB(screen->format, 255 - w, 255 - w, 255 - w));
@ -18867,7 +18869,7 @@ int do_color_picker(void)
#ifndef NO_PROMPT_SHADOWS
alpha_surf = SDL_CreateRGBSurface(SDL_SWSURFACE | SDL_SRCALPHA,
(320 - 96 * 2) + (w - 4) * 2,
(PROMPT_W - 96 * 2) + (w - 4) * 2,
(w - 4) * 2,
screen->format->BitsPerPixel,
screen->format->Rmask,
@ -18882,9 +18884,9 @@ int do_color_picker(void)
for (i = 8; i > 0; i = i - 2)
{
dest.x = 160 + 96 - (w - 4) + i + PROMPTOFFSETX;
dest.x = PROMPT_LEFT + 96 - (w - 4) + i + PROMPTOFFSETX;
dest.y = 94 + 96 - (w - 4) + i + PROMPTOFFSETY;
dest.w = (320 - 96 * 2) + (w - 4) * 2;
dest.w = (PROMPT_W - 96 * 2) + (w - 4) * 2;
dest.h = (w - 4) * 2;
SDL_BlitSurface(alpha_surf, NULL, screen, &dest);
@ -18899,16 +18901,16 @@ int do_color_picker(void)
w = w - 6;
dest.x = 160 + 96 - w + PROMPTOFFSETX;
dest.x = PROMPT_LEFT + 96 - w + PROMPTOFFSETX;
dest.y = 94 + 96 - w + PROMPTOFFSETY;
dest.w = (320 - 96 * 2) + w * 2;
dest.w = (PROMPT_W - 96 * 2) + w * 2;
dest.h = w * 2;
SDL_FillRect(screen, &dest, SDL_MapRGB(screen->format, 255, 255, 255));
/* Draw color palette: */
color_picker_left = 160 + 96 - w + PROMPTOFFSETX + 2;
color_picker_left = PROMPT_LEFT + 96 - w + PROMPTOFFSETX + 2;
color_picker_top = 94 + 96 - w + PROMPTOFFSETY + 2;
dest.x = color_picker_left;
@ -18952,7 +18954,7 @@ int do_color_picker(void)
color_example_dest.x = color_picker_left + img_color_picker->w + 2;
color_example_dest.y = color_picker_top + 2;
color_example_dest.w = (320 - 96 * 2) + w * 2 - img_color_picker->w - 6;
color_example_dest.w = (PROMPT_W - 96 * 2) + w * 2 - img_color_picker->w - 6;
color_example_dest.h = 124;
@ -18985,7 +18987,7 @@ int do_color_picker(void)
/* Show "Back" button */
back_left = (((320 - 96 * 2) + w * 2 - img_color_picker->w) - img_back->w) / 2 + color_picker_left + img_color_picker->w;
back_left = (((PROMPT_W - 96 * 2) + w * 2 - img_color_picker->w) - img_back->w) / 2 + color_picker_left + img_color_picker->w;
back_top = color_picker_top + img_color_picker->h - img_back->h - 2;
dest.x = back_left;

View file

@ -10,7 +10,7 @@ Name[br]=Tux Paint
Name[ca]=Tux Paint
Name[cs]=Tux Paint
Name[cy]=Tux Paint
Name[da]=Tux maling
Name[da]=Tux Paint
Name[de]=Tux Paint
Name[el]=Tux Paint
Name[en_AU]=Tux Paint
@ -47,8 +47,8 @@ Name[nn]=Tux Paint
Name[nr]=ITux Pende
Name[oc]=Tux Paint
Name[pl]=Tux Paint
Name[pt]=Tux Paint
Name[pt_BR]=Tux Paint
Name[pt_PT]=Tux Paint
Name[ru]=Рисуй вместе с Tux!
Name[sk]=Kreslenie s Tuxom
Name[sl]=Tux Paint
@ -86,7 +86,7 @@ GenericName[br]=Meziant tresañ
GenericName[ca]=Programa de dibuix
GenericName[cs]=Kreslicí program
GenericName[cy]=Rhaglen lunio
GenericName[da]=Tegne program
GenericName[da]=Tegneprogram
GenericName[de]=Malprogramm
GenericName[el]=Πρόγραμμα ζωγραφικής
GenericName[en_AU]=Drawing program
@ -124,8 +124,8 @@ GenericName[nn]=Teikneprogram
GenericName[nr]=Iphrogremu youkudweba
GenericName[oc]=Logicial de dessenh
GenericName[pl]=Program do rysowania
GenericName[pt]=Programa de desenho
GenericName[pt_BR]=Programa de desenho
GenericName[pt_PT]=Programa de desenho
GenericName[ro]=Program de desenat
GenericName[ru]=Программа для рисования
GenericName[sk]=Program na kreslenie
@ -196,8 +196,8 @@ Comment[nl]=Een tekenprogramma voor kinderen.
Comment[nn]=Eit teikneprogram for dei yngste.
Comment[nr]=Iphrogremu yokudweba yabantwana.
Comment[pl]=Program do rysowania dla dzieci.
Comment[pt]=Um programa de desenho para crianças.
Comment[pt_BR]=Um programa de desenho para crianças.
Comment[pt_PT]=Um programa de desenho para crianças.
Comment[ro]=Un program de desenat pentru copii
Comment[ru]=Детская программа для рисования.
Comment[sk]=Program na kreslenie pre deti.