181 Commits

Author SHA1 Message Date
Thomas Bernard
a29168f7ce Splash screen : 2017->2018 2018-03-20 21:58:22 +01:00
Thomas Bernard
30f23b93ef Massive change of button callback function prototypes 2018-03-10 00:46:11 +01:00
Thomas Bernard
f2d579695c implements selection of circle/ellipse mode with right button
see http://pulkomandy.tk/projects/GrafX2/ticket/54
2018-03-10 00:46:11 +01:00
Thomas Bernard
60beebc9ac fixes for MSVC non-standard C library
strcase => _stricmp
strncase => _strnicmp
strdup => _strdup
snprintf => _snprintf

a compliant snprintf() is supposed to be available
in MS Visual Studio 2015 and later
2018-02-20 15:45:45 +01:00
Thomas Bernard
ad219c84d2 Make saving of unicode named files work under Win32
the "Long" name is converted to short (DOS 8.3) name
as soon as possible.
2018-02-20 15:45:45 +01:00
Thomas Bernard
6f48d7fefe Add MSVC 2010 project file and a make the project compile 2018-02-20 15:45:45 +01:00
Thomas Bernard
9fb6d650b5 pass unicode name when clicking Load or Save button 2018-02-20 15:44:39 +01:00
Thomas Bernard
4a2754321f update For_each_file() to pass both full path and file name only to the callback
All  callbacks need to extract the filename anyway, so it simplify the code
2018-02-20 15:44:39 +01:00
Thomas Bernard
a4593da4d4 display unicode filename in menu 2018-02-20 15:44:39 +01:00
Thomas Bernard
545308265b Add the ability to print unicode characters in addition to "Latin1" ones 2018-02-20 15:44:39 +01:00
Thomas Bernard
4ffa389a90 Update File selector to load/save palettes
Also "constify" the format array
2018-01-25 22:55:27 +01:00
Thomas Bernard
abe7a8cb59 simplification of in Load_picture() 2018-01-25 22:55:27 +01:00
Thomas Bernard
76f3860712 fix after rebase 2018-01-25 22:55:27 +01:00
Thomas Bernard
ccf3e6a77f Change Load_picture() prototype to allow loading of palette
the change matches what is done with Save_picture()
2018-01-25 22:55:27 +01:00
Thomas Bernard
5ab93eb7fd Great simplification of Main/Spare page flipping 2018-01-22 21:47:44 +01:00
Thomas Bernard
353b494617 move tilemap data to T_Document.
Also merge Disable_main_tilemap + Disable_spare_tilemap
=> Disable_tilemap()
2018-01-22 20:59:49 +01:00
Thomas Bernard
92620bb4ba merge Upload_infos_page_main() / Upload_infos_page_spare() => Upload_infos_page() 2018-01-22 20:34:29 +01:00
Thomas Bernard
a53d6da6ea Add visible_image and backups to the T_Document structure 2018-01-22 16:16:39 +01:00
Thomas Bernard
8ae651c75f put common fields for Main and Spare page in a T_Document structure 2018-01-22 14:46:44 +01:00
Thomas Bernard
2928a16e41 Also save visible layers for spare page
see http://pulkomandy.tk/projects/GrafX2/ticket/25#comment:3
2018-01-03 05:13:51 +01:00
Adrien Destugues
f2b04e08d0 Constraint modes: Thomson, ZX 2017-06-23 22:20:08 +02:00
Adrien Destugues
aef77744e1 EGX mode for CPC
In this custom mode, odd lines use MODE 0 (wide pixels, 16 colors), and
even lines use MODE 1 (square pixels, 4 colors).

- Add a settings window to the 8-bit effect where you can chose what you
want to draw
- Add the customizations required to make it work in graph.c
- Tweak some other places so it is easier to add other modes later on.
- Groundwork for some more modes: EGX2, ZX spectrum, Game Boy color.
2017-05-06 22:22:52 +02:00
Adrien Destugues
a8c7cdff15 Update copyright year in headers. 2017-05-01 20:41:46 +02:00
Adrien Destugues
7be396a9cf Splash screen: fix homepage and copyright
* 10 years since I started porting GrafX2 to SDL!
* 20 years since Sunset Design wrote the first lines of code!
* To celebrate this, I'm finally setting up a real website!
2017-05-01 13:57:51 +02:00
Adrien Destugues
8808625851 Add a "tall 3" drawing mode.
Pixels with 3:4 aspect ratio. Why not?

Contributed by Nic Soudée (zoner/xylem). Thanks!


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2166 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2016-10-15 18:57:14 +00:00
Yves Rizoud
54b4269103 Effects screen : remove underlines on 'X' buttons (Underline is supposed to be used on letter whose key acticvates the button)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2123 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-06-28 15:44:12 +00:00
Adrien Destugues
e187ade14c Effects: forgot some changes when rearranging buttons
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2115 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-07 08:34:18 +00:00
Adrien Destugues
78b5ab394b Popup menu to switch between drawing modes more easily
Fixes https://code.google.com/p/grafx2/issues/detail?id=510


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2113 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-04 14:33:06 +00:00
Adrien Destugues
32defb8897 fix "save as" not showing the current filename
* We attempted to set this but it was overwritten when enumerating the files.
* This makes it easier to save the file in the same dir, with another name.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2111 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-04 10:12:18 +00:00
Adrien Destugues
fa80a10093 Implement "save palette" button
* Actually a shortcut to "save picture" with preset PAL format and different window title.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2110 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-04 10:08:34 +00:00
Adrien Destugues
26458456a8 Move the "show grid" setting to the effects window.
Fixes https://code.google.com/p/grafx2/issues/detail?id=315


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2108 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-03 16:07:39 +00:00
Adrien Destugues
0f64436854 Effects: group them by type
* On the left: "feedback" effects, with the checkbox to enable feedback.
* On the right: "grid" effects, which use the grid settings.
* On the middle: everything else.

"Grid" effect is renamed to "Snap".


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2107 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-03 15:55:57 +00:00
Adrien Destugues
78fcc648c3 Partial merge of the SDL2 branch into trunk
* Mainly get the cleanup of window drawing functions.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2102 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2015-03-02 13:44:18 +00:00
Adrien Destugues
e19026860d Update the URLs in several place to stop pointing to googlecode.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2069 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2014-01-13 12:36:22 +00:00
Yves Rizoud
365cc8d50b Fix issue 539 : Freeze when palette is 'vertical' and number of rows is not a power of two
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2064 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2013-08-30 00:05:47 +00:00
Adrien Destugues
878c926ce4 Fix issue 185 (XOR highlight) :
* Use a simple optimization algorithm to compute a good set of XOR color pairs
 * Algorothm is not very optimized (complexity is up to n^3). In practize, it stabilizes after 2 to 3 rounds of swapping colors
 * Use this color table for all XOR effects
 * Setting for grid color is now removed


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2048 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2013-01-06 12:46:46 +00:00
Yves Rizoud
e87f9140c7 Fix issue 516: Some changes can't be undone on animations > 32 frames
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2033 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-10-16 00:07:42 +00:00
Yves Rizoud
919357ab46 Fix crash when loading 24-bit brushes
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2020 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-29 16:01:53 +00:00
Yves Rizoud
26613ec440 Program now remembers favorite mode layers/anim, based on last time you switched in splash screen or toolbar. Fixed graphic behavior when mode 5 is enabled/disabled, and added a safety (colors <4).
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2014 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-28 00:19:57 +00:00
Yves Rizoud
1efe6ec5be Fix issue 460: brush 180° rotation. Also, the keyboard shortcut had no effect at all
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2008 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-25 22:05:32 +00:00
Yves Rizoud
030f4a716f Splash screen asks the user for Layers/Anim mode
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2007 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-23 18:18:06 +00:00
Yves Rizoud
80fc7da7f6 Fix issue 462: Save/Load path problems: Main, Spare and Brush now have completely distinct fileselector settings.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2003 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-22 16:47:39 +00:00
Yves Rizoud
5a2e556f18 Fix a problem when exporting a single layer or anim frame, the chosen format was kept as the file's 'current format'. Also improve Brush load/save which has now mostly separate settings
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2002 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-21 20:10:33 +00:00
Yves Rizoud
440f04ad4f Fix issue 508: corrupted graphics when switching between layers and anim modes
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@2001 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-21 18:54:53 +00:00
Yves Rizoud
144a28412b Issue 453 : Virtual keyboard setting
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1999 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-09-18 23:41:55 +00:00
Yves Rizoud
a630a84822 Removed all usage of __attribute__((unused)), replaced by void cast which is supported both on GCC and VBCC
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1984 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-08-11 16:19:07 +00:00
mazzearos
d28a1df60b Renamed Find_last_slash() to Find_last_separator() to make purpose more clear.
Append_path():
- when adding sub directories: don't add a "/" when last separator is a ":".
- when climbing upwards: don't remove the ":" it it's the last separator.

Those fixes help the file selector for scripts on AROS.


git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1979 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-08-05 08:51:16 +00:00
Yves Rizoud
2afad0b550 Fix issue 483 : Saving layers/anim as non-GIF saves only layer/frame 0. Now with anim it asks confirm then saves current frame, and for layers it allows saving current layer or flattened copy.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1950 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-05-08 15:39:48 +00:00
Yves Rizoud
bbd0d0114c Fix an error in previous commit. Zero warnings on Windows too (Mingw, gcc 4.4.1-TDM)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1946 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-05-03 22:46:04 +00:00
Yves Rizoud
55f4884e34 Fix a few compilation warnings on Linux; Fix a possible bug in Mode5 loader; Removed a pair of debug printfs in realpath.c
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1933 416bcca6-2ee7-4201-b75f-2eb2f807beb1
2012-03-14 19:17:35 +00:00