Grid Sage Forums

Grid Sage Forums

  • November 24, 2024, 09:43:42 AM
  • Welcome, Guest
Please login or register.

Login with username, password and session length
Advanced search  

News:

LINKS: Website | Steam | Wiki

Author Topic: Paste text with background colors  (Read 3502 times)

Eagoth

  • Unaware
  • *
  • Posts: 6
    • View Profile
    • La Motosierra de Ockham
Paste text with background colors
« on: October 12, 2016, 10:30:05 AM »

Hello, guys.

I have a text.xp file with a lot of text, and colors.xp with colors from a png (converted to xp using the cmd png2xp magic). Both xp files have 102x58 cells, and I want for each character of text.xp to have the color of the corresponding cell of colors.png.

Is it possible to do this with REXPaint? I'm pretty new to it and I tried several copy-paste combinations with no luck.

I think I could do it if the png had the colors on foreground instead of background :/

Thanks a million!
« Last Edit: October 12, 2016, 10:32:57 AM by Eagoth »
Logged

Kyzrati

  • Administrator
  • True Cogmind
  • *****
  • Posts: 4477
    • View Profile
    • Cogmind
Re: Paste text with background colors
« Reply #1 on: October 12, 2016, 10:40:19 AM »

I see what you mean, so you have background colors and want to apply them to the foreground text... There is currently no command to perform that action, so it would have to be done cell by cell using color swapping. Yeah, obviously not going to happen, I know :P.

I'm going to do a little update to REXPaint soon for another feature request, so I'll see what I can do for you in this regard and get back to you. I think one option that would work here (and possible have applications elsewhere?), would be to create a command that simply swaps the foreground and background colors throughout an image, so you could fill colors.xp with the solid foreground character (any color), then swap background/foreground colors, then use the copy feature to copy the entire thing, then paste it over the text image (with glyph application turned off--just the foreground color). How's that sound?
Logged
Josh Ge, Developer - Dev Blog | @GridSageGames | Patreon

Eagoth

  • Unaware
  • *
  • Posts: 6
    • View Profile
    • La Motosierra de Ockham
Re: Paste text with background colors
« Reply #2 on: October 12, 2016, 01:18:46 PM »

Yes, that would be useful. Thanks for answering so quickly! :)

Amazing work with the application and the game, by the way. I'm being very inspired by a lot of things of Cogmind.
Logged

Kyzrati

  • Administrator
  • True Cogmind
  • *****
  • Posts: 4477
    • View Profile
    • Cogmind
Re: Paste text with background colors
« Reply #3 on: October 13, 2016, 08:47:36 PM »

Thanks, and here's your patch :) (Edit: Feature now included with v1.04)

The new command is Shift-Alt-w to swap the foreground/background colors throughout the active layer (or Ctrl-Shift-Alt-w to do this for all layers simultaneously). Just use the process I suggested above and you should be able to combine the images as needed!

Here's a sample of the new swap feature in action:
« Last Edit: June 19, 2018, 06:57:22 PM by Kyzrati »
Logged
Josh Ge, Developer - Dev Blog | @GridSageGames | Patreon

Eagoth

  • Unaware
  • *
  • Posts: 6
    • View Profile
    • La Motosierra de Ockham
Re: Paste text with background colors
« Reply #4 on: October 16, 2016, 01:48:41 PM »

That worked perfectly, thank you very much! :)
Logged

Kyzrati

  • Administrator
  • True Cogmind
  • *****
  • Posts: 4477
    • View Profile
    • Cogmind
Re: Paste text with background colors
« Reply #5 on: October 16, 2016, 11:00:12 PM »

Excellent, glad to be of service!
Logged
Josh Ge, Developer - Dev Blog | @GridSageGames | Patreon