map_editor: read rgb macros instead of binary data for palettes

also fix tileset graphics handling