[x] I have searched the issues of this repo and believe that this is not a duplicate
OS version and name: Mac OS 10.13.2
I'm trying to update the hyper-cat plugin to work with Hyper 2. Unfortunately, my decorateConfig method never gets called. Is this a known issue or am I missing something. I've tried narrowing it down by commenting everything else out, but it still doesn't get called. Here's my current work-in-progress that demonstrates the issue: https://github.com/Aaronius/hyper-cat/blob/89d734b146de09ce5cd7c11ee73318cd263914bd/index.js
decorateConfig should get called and therefore log the config to the console, but it never gets called.
BTW, my next somewhat related question will be: is there any way hyper-cat can toggle the xterm-text-layer canvas background opacity (on and off as the user types and stops typing)? The nyan must shine through in all its glory while the user is typing..
your console.log should be displayed where you typed yarn app. Because this function is executed on main thread, not on renderer.
you can toggle opacity by changing the background color (If background color is not opaque, xterm canvas background will be transparent). But changing it has a cost, regenerating char atlas, redraw etc...
I will suggest you to always set a 0.99 alpha color if your plugin is used with an opaque background color. The only downside is that it will disable subpixel antialiasing but I wonder if hyper-cat users do care 馃槢
Thanks @chabou, that helps a lot. I'm able to set the backgroundColor to transparent through decorateConfig, but what I'd really like to do is toggle it at runtime instead. In other woreds, I'd like the user to be able to define whatever background they normally prefer (using backgroundColor), and then at runtime when the user starts typing, I need to change their background with the nyan background, but that also requires me to, at runtime, set backgroundColor to transparent so that xterm-text-layer doesn't cover up the nyan background. Does that make sense? Thanks for your help.
@Aaronius To toggle the background-color at runtime, I think that you can use getTermProps API handler.
Thanks. I'll give it a go sometime. My original problem has been resolved, so I'm going to close this issue. Thank you.
Most helpful comment
BTW, my next somewhat related question will be: is there any way hyper-cat can toggle the xterm-text-layer canvas background opacity (on and off as the user types and stops typing)? The nyan must shine through in all its glory while the user is typing..