Commit graph

42 commits

Author SHA1 Message Date
Bill Kendrick
18f9cad6fe Adding "indent.sh" to re-indent code; ran it!!! 2023-04-23 23:26:00 -07:00
Bill Kendrick
cc05925d9e Re-ran indent on all .c & .h source code files
Like so --
  find . -name "*.c" -or -name "*.h" -exec  indent -nbfda -npcs -npsl -bli0 --no-tabs {} \;

The `indent` invocation differs from the last one noted in
CHANGES.txt (from 2006!?), in that I've added "--no-tabs",
to ensure indents are all space-based.
2022-09-15 00:14:20 -07:00
Bill Kendrick
e1fc4d60e7 Wrapping a printf in im.c in a debug #ifdef 2022-05-19 23:29:19 -07:00
Pere Pujal i Carabantes
eb7f55e289 Merge branch 'master' into sdl2.0
Some things are still WIP, they need to be tested and addressed later.
2022-02-17 23:57:28 +01:00
Mark Kim
e1ecf80e26 Fix random crashes in Korean, Japanese, and some other languages
Occasionally running Tux Paint in Korean, Japanese, and possibly other
languages would cause Tux Paint to crash.  This commit fixes it.

This bug was previously mentioned as the possible cause of these
previously reported crashes, though they were determined to be
unrelated:

  https://sourceforge.net/p/tuxpaint/mailman/message/37364981/
  https://sourceforge.net/p/tuxpaint/mailman/message/37376574/

The cause of the crash turned out to be in the function that loads the
input method map (*.im).  Some languages that use more than one
keystroke to produce one unicode character use this mapfile to track, in
a state machine, what keys have been pressed and what unicode character
should be output.  This state machine's memory is increased dynamically
as needed when the input method map file is loaded.  There was a line of
code that references the old memory that could have moved by the memory
increase.  This line of code has been moved to prior to the memory
increase to avoid accessing memory that may have moved.
2022-02-06 21:02:06 -05:00
Pere Pujal i Carabantes
4749214383 Onscreen keyboard working on Windows, by TOYAMA Shin-ichi. 2021-12-15 20:35:43 +01:00
Pere Pujal i Carabantes
1afe9e155c Merge branch 'master' into sdl2.0
Tons of bugfixes and improvements for Windows by Toyama Shin-Ichi
Angle rotation and some magic tools by Bill.
2021-11-06 08:59:22 +01:00
dolphin6k
6145fb8bc2 Addressed some compile time warnings. 2021-11-03 22:04:24 +09:00
Pere Pujal i Carabantes
9cf77f684c Merge branch 'master' into sdl2.0
There are problems with im that should be investigated...
2021-10-24 11:47:54 +02:00
dolphin6k
e1492d3b65 Left Alt key also mapped to the switch for Japanese. (I found my laptop does not have right Alt ;-)
How about for Thai?
2021-10-15 16:49:24 +09:00
Pere Pujal i Carabantes
b6b0636eb5 Merge branch 'master' into sdl2.0 2021-09-27 23:32:48 +02:00
Mark Kim
4b83412ea7 IM debugging updates
- Control debugging via debug.h (previously im.c had its own
  defined constant to control this.)
- Remove reference to an undefined symbol im_event_fp within a DEBUG
  block.

Also:
- Explicitly include i18n.h required by im.c (though it appears to be
  getting included by another file indirectly.)  This should be a no-op
  change.
2021-09-23 17:07:40 -04:00
Pere Pujal i Carabantes
a1c778135d Merge branch 'master' into sdl2.0
Merging master 2019-september-24 into sdl2.0 branch
2019-09-24 14:52:40 +02:00
Bill Kendrick
df49986fab Add a FALL_THROUGH macro to compiler.h
Older gcc's don't support `__attribute__ ((fallthrough))`
(see https://sourceforge.net/u/begasus/tuxpaint/ci/e5c3cdfcf5e16a9b0fc3e7766bfea1d9c326b3ae/
"Haiku Fixes" by Luc), so adding a new macro to compiler.h
that is defined as "((void)0)" on older compilers.
2019-09-12 20:27:03 -07:00
begasus
e5c3cdfcf5 Haiku fixes 2019-09-06 13:45:56 +02:00
Bill Kendrick
7938480174 Clean up GCC warnings (2019-08-29 edition)
Updated most parts of the code that were throwing warnings in GCC.
2019-08-30 00:01:00 -07:00
Pere Pujal i Carabantes
4d3ef642da Updating to master 2019/6/6 2019-06-06 20:22:55 +02:00
Bill Kendrick
4e3a9fbc8c Re-ran indent on .c files
Also, added a few places where indent is disabled
(via `/* *INDENT-OFF* */`).

See https://sourceforge.net/p/tuxpaint/mailman/message/36077409/
from Oct. 2017.
2019-04-13 12:00:44 -07:00
Pere Pujal i Carabantes
c6b6958cf3 More compiler warnings 2017-12-19 02:41:56 +01:00
Pere Pujal i Carabantes
1e0ea6d4b3 Indentation. 2017-12-19 02:17:27 +01:00
Pere Pujal i Carabantes
ede838caf9 Syncing with the android version... 2017-12-06 06:39:41 +01:00
Pere Pujal i Carabantes
356b503bdd Recovering IM in a more generic way. 2017-12-06 06:39:40 +01:00
Pere Pujal i Carabantes
ee3529b7bf Recovering Traditional Chinese IM 2017-12-06 06:39:40 +01:00
Pere Pujal i Carabantes
b08ddf00dd Keyboard input seems to work, even dead keys, not tested IM, onscreen keyboard not working... 2017-12-06 06:39:37 +01:00
Pere Pujal i Carabantes
4c69fdbb43 Some more progress on SDL2, render seems to begin working. 2017-12-06 06:39:37 +01:00
Pere Pujal i Carabantes
75089ea473 First attempts to port to SDL2 2017-12-06 06:39:37 +01:00
Bill Kendrick
717b13a866 Correct im.c compiler warnings
* Don't ignore a fscanf()'s output.
 * Rewrite some increment/roll-overs to avoid, e.g.
   src/im.c:1193:18: warning: operation on ‘cm.section’ may be undefined [-Wsequence-point]
        cm.section = (++cm.section % SEC_TOTAL);  /* Change section */
2017-10-15 14:48:31 -07:00
Bill Kendrick
0796dc924c indent im.c im.h 2017-10-15 10:58:14 -07:00
William Kendrick
e990b48de7 Large bundle of OS X tweaks by Eric P. (basis of the 10.9-compatible
pre-release made in Dec. 2013):
 * Fix OS X 10.9 issue of current directory set by Finder
   to something else than folder where app bundle resides.
 * Some Mac OS X build / project changes & updates.
 * Adjustments to Mac OS X fontconfig config file, to avoid warnings
   and make things more robust.
 * Updates to some #include's to catch up with newer library revisions.
 * Tweaks to pixel read/write on Apple.
 * Introduction of 'intprt_t' casting to avoid warnings on x64.
 * Some additional debugging output.
 * Logging stderr & stdout to /tmp/tuxpaint.log
Untested (I don't have a Mac!)
2014-03-19 23:39:17 +00:00
Albert Cahalan
3d15a468cd lots of functions made static (some had to be moved) 2009-11-22 23:17:35 +00:00
Shin-ichi TOYAMA
b04d4720ce Some debug messages were disabled for old environment which don't have
fwprintf(), such as redhat-6.x.
2008-06-27 02:35:26 +00:00
William Kendrick
0668cd3b47 Removed _APPLE_10_2_8_-related stuff. 2008-05-28 14:43:25 +00:00
Martin Fuhrer
04506fa385 Updates for 0.9.19 release. Added authorization code to permit Fontconfig files to be installed on first launch from a non-admin account. Fixed possible lockups in fullscreen mode when attempting to print. 2008-02-05 06:30:23 +00:00
William Kendrick
344492dad4 BeOS updates. 2007-12-07 00:05:45 +00:00
William Kendrick
618840c668 Fixed syntax error. 2007-11-06 15:53:15 +00:00
Song Huang
7ebd2dd782 Add Chinese Traditional IM support, Please kindly help me to inspect the codes, Thanks! 2007-11-04 12:43:01 +00:00
William Kendrick
21ea42f38f Attempting to debug/fix SDL_Pango stuff.
Added icon for Kalidescope magic tool.
Added Canada map starter.
Added Japan map starter.
Improved comments near gettext() calls to improve POT and PO files.
Regenerated PO files and POT file.
Added .cvsignore to make sure tp_magic_api.h (which is generated) isn't noticed.
2007-07-17 18:41:16 +00:00
William Kendrick
abf6a2a1bb Attempting to add Thai input method. 2007-07-08 07:27:12 +00:00
Mark K. Kim
c735e6a6b8 Crash bug due to IM fixed, variable name change. 2007-05-06 04:00:20 +00:00
Mark K. Kim
0ea24f916b Korean IM crash bug fix, add L-ALT for mode switch. 2007-04-30 04:04:39 +00:00
Mark K. Kim
cf0a8a7bee IM: unicode _string_ output support. 2007-04-27 03:43:27 +00:00
Mark K. Kim
f043a733e6 Added application-level Input Method support. 2007-04-22 04:05:23 +00:00