Some probably basic EMCO customization questions

Bigglesbee
Posts: 24
Joined: Wed Aug 10, 2022 4:13 pm

Some probably basic EMCO customization questions

Post by Bigglesbee »

Heya, just got EMCO installed and the tabs/captures set up. Working great so far, but I have a few probably basic questions about customizing it:
  1. Is there a way to change the timestamp to non-military time?
  2. Is there a way to visually separate the timestamp, too? Like with different colors or a character like a colon?
  3. Is there a way to change the colors of the whole container (ex: the green border) rather than just the tab colors?
  4. Is there a way to save all the settings so I can load the same exact container/colors/tabs/captures in different character profiles?
  5. Can you manually clear the EMCO?
  6. Any way to change the color/speed of the tab blink?
  7. Finally: If I am in another character tab and the EMCO captures messages/updates the container in a non-focused character tab, the messages will be squished over to the left when I go back to that character tab, word-wrapping after only 2-4 words. Any way to fix that?
I saw the reference page, but I'm not a coder, so I'm not really sure how to use all those extra options, some of which I realize would answer some of my above questions.

Thanks in advance!

User avatar
demonnic
Posts: 884
Joined: Sat Dec 05, 2009 3:19 pm

Re: Some probably basic EMCO customization questions

Post by demonnic »

When you say you installed emco, does that mean you installed the prebuilt chat package at https://github.com/demonnic/EMCO ? The specific answers change a bit depending.

Except for 7, if you mean you have two characters in different tabs in the same mudlet there's an issue right now where it is reporting an incorrect size, which is causing it to wrap in the wrong place. Should be able to help you work around it but again the specific answers will depend a bit on how you installed emco.

Bigglesbee
Posts: 24
Joined: Wed Aug 10, 2022 4:13 pm

Re: Some probably basic EMCO customization questions

Post by Bigglesbee »

Heya, I installed EMCO via the lua installPackage then emco update commands from within Mudlet, the ones in the instructions from the link you mentioned.

And yeah, that wrap issue you explained seems exactly like what is happening!

User avatar
demonnic
Posts: 884
Joined: Sat Dec 05, 2009 3:19 pm

Re: Some probably basic EMCO customization questions

Post by demonnic »

Once you get your emco configured how you want it, using "emco save" should save all the options so they come back. For code below, you can run it using the built in lua alias, for instance:

Code: Select all

lua demonnic.chat:setTimestampFormat("hh:mm:ssA")
I don't include it in every instance. You can add it to your own aliases if you like, without the "lua" in front.

1. demonnic.chat:setTimestampFormat("hh:mm:ssA") would set it to 07:21:28PM . It's pretty flexible

2. The character formatting is what you set in the above, so if you want 07|21|28pm you could use "hh|mm|ssa". Also, you can use demonnic.chat:setTimestampBgColor("red") and setTimestampFgColor to change the overall fg and bg colors. It uses decho, so if you want to set individual elements you should be able to do demonnic.chat:setTimestampFormat("<255,0,0>hh<r>:<0,255,0>mm<r>:<0,0,255>ss<r>A") to make hours red, minutes green, and seconds blue.
timestamp.png
timestamp.png (868 Bytes) Viewed 4157 times
3. The green border is actually from the adjustable container. You could change this, but I think I'll add it to the emco color alias and do a release soon, as changing this is a bit more bothersome than you may be up for, and I may as well make it available to everybody.

4. They are saved to files in your profile directory. The following commands in Mudlet will show you the directories to copy from

Code: Select all

-- you want the EMCOPrebuilt*.lua files from here. There are 2 of them
lua getMudletHomeDir() .. "/EMCO/"
-- you want EMCOPrebuiltChatContainer.lua from the following dir
lua getMudletHomeDir() .. "/AdjustableContainer/"
5. To clear the contents of all the tabs demonnic.chat:clearAll() and to clear a single tab demonnic.chat:clear("tabname")

6. No on the color, it uses Geyser's built-in flash(). You can adjust the time in between the flashes by using demonnic.chat:setBlinkTime(0.5) to set it to half a second, for instance.

For 7, you can set the wrap width manually by doing

Code: Select all

-- https://demonnic.github.io/mdk/current/classes/EMCO.html#EMCO:disableAutoWrap
demonnic.chat:disableAutoWrap()
-- https://demonnic.github.io/mdk/current/classes/EMCO.html#EMCO:setWrap
demonnic.chat:setWrap(20)
And find a wrap width which works for you. Should keep it from getting squished when you're in another tab.

User avatar
demonnic
Posts: 884
Joined: Sat Dec 05, 2009 3:19 pm

Re: Some probably basic EMCO customization questions

Post by demonnic »

ok, if you "emco update" I just pushed a release which fixed some issues with the way it was loading color preferences, and also adds windowBorder as something you can change the color of.

Bigglesbee
Posts: 24
Joined: Wed Aug 10, 2022 4:13 pm

Re: Some probably basic EMCO customization questions

Post by Bigglesbee »

Thanks, I'm checking this all out now!

If I wanted to mess with other variables, does that format work for all the things from the reference list? lua demonnic.chat:set[variable]?

User avatar
demonnic
Posts: 884
Joined: Sat Dec 05, 2009 3:19 pm

Re: Some probably basic EMCO customization questions

Post by demonnic »

Should work for most of it, I tried to be fairly consistent. But when in doubt reference the docs =)

Bigglesbee
Posts: 24
Joined: Wed Aug 10, 2022 4:13 pm

Re: Some probably basic EMCO customization questions

Post by Bigglesbee »

Okay most of this is working great -- window color looking good, etc -- but the timestamp format/color doesn't seem to be working right. The first timestamp change worked well, then I tried doing the colors and neither worked, then I tried changing the format again just to see how it looked, and that didn't work.

I'm doing it with the lua demonnic.chat:set stuff copy/pasted from up above. Feel like I must be missing something!

User avatar
demonnic
Posts: 884
Joined: Sat Dec 05, 2009 3:19 pm

Re: Some probably basic EMCO customization questions

Post by demonnic »

so demonnic.chat:setTimestampFormat("hh:mm:ssA") works for me, but I outclevered myself and tried to restrict the character in use for the timestamp format to valid replacements. Which in hindsight was maybe kind of dumb and I might undo that.

You might also need to do demonnic.chat:enableCustomTimestampColor() to get the FG/BG ones working

Bigglesbee
Posts: 24
Joined: Wed Aug 10, 2022 4:13 pm

Re: Some probably basic EMCO customization questions

Post by Bigglesbee »

Okay so, this almost worked!

I enabled the FG and BG timestamp colors, then I'm able to change the FG and BG of the timestamps using lua demonnic.chat:setTimestampFGColor("color"), and the colors change. I do an emco save, then I quit out of the MUD and close the client. When I re-open the client, the timestamp color settings revert back to how they were when originally enabled rather than the colors I set. I can re-set them and they're accepted and change, but it won't save whenever I close/open the client. Any idea why?

Thanks for all this help by the way!

Post Reply