Support Aliases in a manner similar to mIRC, but allow them to be inline as well.
The first step would be to create an alias. You click on a button “Add and Alias”.
A windows pops up with three text boxes. A small one about 15 characters for a the alias name, a second longer text box of about 60 characters for an alias description and a third text box with a scroll bar that would accommodate 3000 characters or whatever the max message size Campfire allows. Most aliases would only be a few characters.
An example alias for the small box would be the letter h.
An example for the second box would be Hello.
An example third box would be Hello %1 welcome to Plex Chat. How can I help you?
There would be a Save button for the user to save the alias and a Cancel button to not save the new alias.
Here is a simple scenario:
A user joins the chat and says Hello. His name is John Butters. There are some other John’s in the chat room.
I type //h <tab><enter> if John Butters was the last person to say something.
Smores types “Hello John Butters welcome to Plex Chat. How can I help you?”
If John was not the last person to say something and the other guy’s name is Paul I would type “//h j <tab><enter>
Smores would go backwards through the usernames in the chat room text looking for the first match to the string before the <Tab>
The Smores user does not have to enter a User Name for a parameter any single word could be used. If multiple words are desired multiple %parameters can be specified %1 %2 %3 would accommodate three words in a row. The %numbers could be in different parts of the message and even repeated in the same text if you want to repeat the text in the message string.
Messages could also contain other aliases, just be careful not to create a message linked back to the original message we don’t want to create a loop, overflow a buffer and crash the program. If the buffer is too large the message would be truncated to the maximum message size before sending.
Short 1 word aliases can cover the most important aliases, but if you have a lot of aliases it can be easy to forget them. Right clicking on a person’s handle in the chat room would display a list of aliases with Descriptions (the second text box). Clicking on an item in the list would send the message substituting the UserName for %1. The list would be scrollable and about 15 items long. It could be alphabetized by description.
Another button would be needed for editing the aliases. Clicking on a button would display the list of aliases and right clicking on the list would give a choice of edit or delete. Edit would display the data as originally entered and could use the same code. Delete would display a confirmation box with Yes and No buttons.
The text box would allow the entry of HTML code for links to images on publically accessible web servers, tables, fonts and text colors, styles and sizes. URL’s could be included and work as they do now.