Some vocabulary :
-We call "screen" the pixels that the user actually sees, including any menu, cursor, opened window. So the function count_used_colors_screen_area counts colors there.
-We call "picture" the pixels that make the full picture, as you want to save it. count_used_colors and count_used_colors_area counts color there.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1015 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Put the correct version of loadsave.c. Sorry I'm a little ill today.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1014 416bcca6-2ee7-4201-b75f-2eb2f807beb1
-However if the pointer is still living (for example a global) you should assign NULL to it to avoid bad ram access and random bugs. Accessing a NULL pointer always gives a segfault, accessing a freed pointer may or may not crash.
-Also fixed a memory leak
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@924 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Fix the minimum screen size not enforced when resizing window (since r705)
Fix the mouse cursor position when changing pixel size (since r705)
In fileselector, the image preview now enforces "safe colors". (issue 116)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@716 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Some code related to this window is still in loadsave.c (stuff for preview)
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@695 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Code "cleanup": Functions that create a button now return its address.
This helps reduce the number of files that use the globals "Fenetre_Liste_boutons_*"
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@642 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Tested OK on Windows when crashing Contour (issue 119)
Doesn't handle frozen states (when killed in task manager), I'll have to look further.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@628 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Reworked GIF Save/Load. Now saves as GI89a, and is able to save and reload text comments.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@624 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Note: can display broken preview if an image is using multiple entries with the same color, and some of them are selected for cm_clair and cm_fonce.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@607 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Also added two experimetal functions, Ouvrir_popup and Fermer_popup, and started to implement a (commented) example popup menu for selecting freehand draw mode.
But it seems there are problem if doing a while(Mouse_K), Mouse_K seems to be reset when the mouse moves, or in some other place. Time to sleep so i'll continue that tomorrow.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@474 416bcca6-2ee7-4201-b75f-2eb2f807beb1
Also, cleans some warnings that occurs with -pedantic -c99 options to gcc, and some little things pointed by splint.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@458 416bcca6-2ee7-4201-b75f-2eb2f807beb1
-Graph.c : everything related to drawing.
-Brush.c : everything related to brushes (displaying, erasing, capturing, and effects)
-Windows.c : windows and menu drawing functions
Some functions were also moved to divers.c.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@396 416bcca6-2ee7-4201-b75f-2eb2f807beb1
All palette functions can be used in HSL color space too (multi-select, etc).
Fixed some more missing refreshes in Palette screen.
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@368 416bcca6-2ee7-4201-b75f-2eb2f807beb1