Important Update: Archer Community Scheduled Maintenance on November 23–24 - New Community Launching Soon! Learn More..
2020-02-20 04:48 AM
Hi Folks,
Does anyone have the custom object to disable the font size, font type from text area field ? Can a unique font size be maintained so that user cant update the text with multiple fonts ?
Thanks,
2020-02-20 01:12 PM
Amit, see if this works.
<style>
#mceu_39-body {
display: none !important;
}
</style>
Advisory Consultant
2020-02-20 01:31 PM
Hi David,
The code completely disable the font , can i give user only to select only 1 font , say "Arial" but not to choose other fonts .
2022-03-08 12:05 PM
I would be interested in the solution as well - When copy pasting often different fonts or sizes occur. @DavidPetty do you have a solution for that?
2022-03-10 07:40 PM
The Archer Advanced Rich Text editor is powered by a commercial library called TinyMCE, you can find their documentation on how to limit the font selection or other UI controls, it's very powerful and you can basically highly customize it per application via Custom Object.
We've customized it previously for a client with a fixed font family and font size, and when the content is empty in a certain condition, add placeholder text as a template for the end-users to fill out. Cannot share the code since it's customized to that specific client but I can describe the general steps:
1. Create a custom object that will only run in edit mode.
2. Find the Archer code that sets the default settings for TinyMCE, it's inside the Javascript file of `ArcherTech.UI.RichTextEditor` class, and called `setDefaultTinyMCESettings`, and inside this function's content, there's `tinyMCE.init` with all those default settings, such as font_format, you can create a new font_format that only contains the ones you needed, and override this `setDefaultTinyMCESettings`.
3. This will run before the user gets into the active state of any TinyMCE instance and your overridden settings will be picked up.