cwensley / pablodraw

PabloDraw is an Ansi/Ascii text and RIPscrip vector graphic art editor/viewer with multi-user capabilities.
MIT License
324 stars 22 forks source link

missing parts when saving after changing colors to newly added custom color #31

Closed neo-backwards-one closed 3 years ago

neo-backwards-one commented 3 years ago

PabloDraw3.3.0-alpha1 on windows 10 (1909)

upon changing some of the original colors, the newly saved .ans file is missing bits and pieces as seen in the pictures.

i included the .ans files although since i stripped it down to the small region of the screenshot, these might not be in their state when the issue originally occured. the original files can be provided if needed.

changed colors are indicated as 01, 02 and 03 in the pictures 01_a.png and 01_b.png

before after delta
01_a.zip (original .ans) 01_b.zip (original .ans) no file included
01_a 01_b 01_c
01 01 -
hue: 160 hue: 160 -
sat: 0 sat: 0 -
bri: 161 bri: 82 -
r: 171 r: 87 -
g: 171 g: 87 -
b: 171 b: 87 -
02 02 -
hue: 160 hue: 160 -
sat: 0 sat: 0 -
bri: 82 bri: 52 -
r: 87 r: 55 -
g: 87 g: 55 -
b: 87 b: 55 -
03 03 -
hue: 160 hue: 160 -
sat: 0 sat: 0 -
bri: 52 bri: 42 -
r: 55 r: 45 -
g: 55 g: 45 -
b: 55 b: 45 -

additionally: since i am not sure if this is the cause of the issue in hand i included the newly added custom colors to the palette as follows (these are all additions, the original colors are untouched):

01 02 03 04 05
hue: 139 hue: 140 hue: 109 hue: 110 hue: 160
sat: 28 sat: 30 sat: 39 sat: 42 sat: 0
bri: 60 bri: 74 bri: 107 bri: 136 bri: 52
r: 56 r: 69 r: 95 r: 125 r: 55
g: 64 g: 79 g: 132 g: 164 g: 55
b: 71 b: 89 b: 122 b: 154 b: 55
cwensley commented 3 years ago

Hey @neo-backwards-one, thanks a ton for filing the issue! Looks like it was because the logic to find the end of the line ignored spaces with color 8 as background, which is obviously incorrect.