fix and document the scale keyword

This commit is contained in:
Albert Cahalan 2004-11-25 06:45:03 +00:00
parent 8be0d5be48
commit f0e9d7b8c3
3 changed files with 20 additions and 2 deletions

View file

@ -12,6 +12,7 @@ http://www.newbreedsoftware.com/tuxpaint/
Albert Cahalan <albert@users.sf.net>
* Added "scale" keyword (*.dat files) for high-resolution stamp images.
Fixed it later; had ":" and "/" flipped around. Documented it.
Albert Cahalan <albert@users.sf.net>
* Can now use pretty much any window size, like 1234x666.

View file

@ -1220,6 +1220,23 @@ New Breed Software</p>
"<code><b>nomirror</b></code>" to the stamp's data file.</p>
</blockquote>
<h4>Initial Stamp Size</h4>
<blockquote>
<p>By default, Tux&nbsp;Paint assumes that your stamp is sized
appropriately for unscaled display on a 608x472 canvas. This is
the original Tux&nbsp;Paint canvas size, provided by a 640x480 screen.
Tux&nbsp;Paint will then adjust the stamp according to the current
canvas size and, if enabled, the user's stamp size controls.</p>
<p>If your stamp would be too big or too small, you can specify
a scale factor. If your stamp would be 2.5 times as wide (or tall)
as it should be, add the option "<code><b>scale 40%</b></code>" or
"<code><b>scale 5/2</b></code>" or "<code><b>scale 2.5</b></code>"
or "<code><b>scale 2:5</b></code>" to your image. You may include
an "<code><b>=</b></code>" if you wish, as in
"<code><b>scale=40%</b></code>".</p>
</blockquote>
<h4>Windows Users</h4>
<blockquote>

View file

@ -8547,7 +8547,7 @@ static info_type * loadinfo(const char * const fname)
if (tmp > 0.0001 && tmp < 10000.0)
inf.ratio = tmp;
}
else if (strchr(cp,':'))
else if (strchr(cp,'/'))
{
tmp = strtod(cp,&cp);
while(*cp && !isdigit(*cp))
@ -8556,7 +8556,7 @@ static info_type * loadinfo(const char * const fname)
if (tmp>0.0001 && tmp<10000.0 && tmp2>0.0001 && tmp2<10000.0 && tmp/tmp2>0.0001 && tmp/tmp2<10000.0)
inf.ratio = tmp/tmp2;
}
else if (strchr(cp,'/'))
else if (strchr(cp,':'))
{
tmp = strtod(cp,&cp);
while(*cp && !isdigit(*cp))