|
|
|
|
|
|
|
|
|
|
|
|
|
|
PROGRAMMING POWER
Changing Rich Text font styles on the Web
By Dan Velasco
Often when creating tips, I open up a can of worms. Usually it's a good can of worms, though, so I'm not complaining. Lots of protein. This is exactly what happened when I wrote a tip about applying stylesheet styles to Notes Rich Text fields on the Web and asked for feedback from you, the faithful DominoPower readers. I received a lot of responses that led me to create a second tip on the same subject. And it also helped me to solve a problem that had been bugging me for months (more about that later). So, in the interest of consolidating the information I've collected into one place, we're reprinting the tips here along with commentary from yours truly.
Applying stylesheet styles to Notes Rich Text fields on the Web This tip is about something that perplexed me for many months until I figured out a solution somewhat by accident. I was trying to apply a stylesheet font to a Rich Text field on a form that was using the default sans serif font. I tried putting the name of the style in the "Class" field on the HTML (Hyper Text Markup Language) properties tab for the Rich Text field, but that didn't work. I then tried putting "<font class="bodyText"> before the field and </font> after the field, marking both as Pass-Thru HTML. The style ended up being applied fine, but the space between the first and second paragraphs on some documents disappeared.
The solution I came up with at the time, which was somewhat kludgey, I'll admit, was to put " " on the line between the first and second paragraphs and mark it as Pass-Thru HTML. This solved the problem, but it made a little extra work for our Production Team. I encountered this problem again recently, but this time I couldn't modify the contents of the Rich Text field because we didn't "own" the database. I started playing again with the code around the field, and what I found is that if I put <span class="bodyText"> before the field and </span> after the field (marking it as Pass-Thru HTML), the correct style was applied to the Rich Text field (the contents of which were using the default sans serif font) and the line between the first and second paragraphs didn't disappear.
Again, please note that the Rich Text fields, to which I applied the stylesheet styles, used the default 10-point Notes sans serif font. If anyone has any other interesting experiences with trying to apply stylesheet styles to Rich Text fields, please send me an email at dvelasco@dominopower.com.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
-- Advertisement --
Find unused Lotus Notes groups and clean up your address book
Have you ever wanted to get rid of old Lotus Notes groups that were cluttering up your address book, but you weren't sure if they were used? Find Unused Groups can help.
Find Unused Groups will check your ACL, mail, multi purpose and server groups to help you determine if they are used, and who uses them.
Learn how to easily clean up your address book. |
-- Advertisement --
Mark your calendar for in-depth Lotus training, May 12-14, Boston
Join experts and peers May 12-14 in Boston for educational and networking events that deliver real-world Lotus training so you can increase productivity and efficiency in your company, advance your skills, and squeeze the most from your current environment. One registration gets you into THE VIEW's Admin2010 and Lotus Developer2010.
Register by April 10 to save $200. |
|
|
|
|
|
|
|
|
|
|