Highlighted

Text Format Information

Community Beginner ,
Apr 29, 2019

Copy link to clipboard

Copied

Hi,

I’m in a Topic that was imported from RH 2017.

When I click in a line, the Font size will be shown, the Font type or the text format won’t.

We should be able to see all the text information.

Pierre

Views

176

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Text Format Information

Community Beginner ,
Apr 29, 2019

Copy link to clipboard

Copied

Hi,

I’m in a Topic that was imported from RH 2017.

When I click in a line, the Font size will be shown, the Font type or the text format won’t.

We should be able to see all the text information.

Pierre

Views

177

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Apr 29, 2019 0
Adobe Community Professional ,
Apr 30, 2019

Copy link to clipboard

Copied

Open the CSS and click the source icon.

I suspect that if you look at the style in question you will see that no font has been defined. It looks OK in RoboHelp because you have a font defined for the body and it is using that. In terms of the particular style though, no font defined specifically for that will mean that nothing shows.

It's useful to have a browser that you don't use normally and set the fonts in that browser to something you would never use. That tests that your CSS will apply to your outputs in the way you want.


See www.grainge.org for free RoboHelp and Authoring information.

@petergrainge

Please use the blue Reply button at the top to help me help you. The black Reply link nests replies and they sort out of order.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 30, 2019 0
Community Beginner ,
Apr 30, 2019

Copy link to clipboard

Copied

Hi,

Thank you for your answer.

No matter what the style says, if I select a Font, say Arial Narrow, I expect it to show when I either click the word or select it. Same thing for the other formats, Bold-Italic-Underline-Size-Color-Margin, I expect them to show if I click a word, select it or the paragraph. If there are different formats in that selection, the different ones can be blank.

Pierre

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 30, 2019 0
Adobe Employee ,
Apr 30, 2019

Copy link to clipboard

Copied

I guess you are talking about the "General" section of the "Properties" panel. The information given there is showing the formatting definitions defined for that element in the CSS. If no information is given (like in your example the font-family) then this formatting information is not defined for that element in the CSS but inherited from some other "parent" element. Or in other words: Inherited styling information will not show, but only information explicitly declared for that element or class.

This is a basic principle in HTML and CSS as well as a basic principle in separating content from formatting.

If you click in a paragraph and select a different font, RoboHelp will add this formatting information to that specific paragraph element only and show this in the properties panel as well. This is called a "local formatting override."

If you want to change the formatting of all elements of a specific type (e.g., "p"), you need to click on the "Styles" tab, hover over the element/style and click the pen icon to edit the style. This will bring you to the CSS Editor where you can edit the style as per your needs, e.g. define the font-family there. Once you save the CSS file, the formatting will be automatically applied to all "p" elements and the formatting information will show in the properties panel. However, it is not good practice in the HTML/CSS world to "double define" one and the same formatting information for a parent element and as well as child element that inherits this information anyway.

That said, I get your requirement that the properties panel should show all formatting information that is applied to a selected element, including inherited information. I will discuss this with the team. From a strict standards compliance perspective, I'm not a big fan of it, as it sort of deludes the very clean and strict approach that is there now. But I get that it would be useful. I could imagine showing all "calculated" formatting information including inherited properties and marking inherited styling information visually in some way.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 30, 2019 0
Adobe Community Professional ,
Apr 30, 2019

Copy link to clipboard

Copied

Stefan.

Please correct me if I am wrong and I may well be. If P, for example, doesn't have a font family defined, then it will inherit what has been set for Body. If nothing has been set for Body, then the content could have one appearance in RoboHelp and the author's browser but something quite different in a user's browser.

My thinking is that by not showing a font, or any other property, you are alerting the author to the fact that it is not defined and that the outcome might not be what they want. I get Pierre's point but maybe with that understanding, it's better as is?


See www.grainge.org for free RoboHelp and Authoring information.

@petergrainge

Please use the blue Reply button at the top to help me help you. The black Reply link nests replies and they sort out of order.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 30, 2019 0
Adobe Employee ,
Apr 30, 2019

Copy link to clipboard

Copied

HI Peter, no, you are not wrong – it's pretty much like you say:

If P, for example, doesn't have a font family defined, then it will inherit what has been set for Body. If nothing has been set for Body, then the content could have one appearance in RoboHelp and the author's browser but something quite different in a user's browser.

More precisely: This is true, if <p> is a direct child of <body>. If font-family is set for <body>, but not for <p>, <p> will inherit the font-family from <body>.

Like in this example:

CSS:

body {

  font-family: Arial;

  background-color: #ffffff;

}

p {

  font-size: 11.0pt;

  margin-top: 4.0pt;

  margin-bottom: 4.0pt;

}

HTML:

<?xml version="1.0" encoding="utf-8" ?>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

  <title>New Topic</title>

</head>

<body>

  <p>Sample text</p>

</body>

</html>

In this scenario, font-family is defined for <body>. <p> had no font-family defined and therefore inherits the font-family (here: Arial) from the "next higher" (ancestor) element (in this case <body>).

If <body> would also have no font-family defined, <p> would be formatted in a browser as it is defined in the browser's default stylesheet.

However, notice that it is not that <p> always inherits from <body>, but from "the first ancestor" that has this value defined.

E.g. this example:

CSS:

body {

  font-family: Arial;

  background-color: #ffffff;

}

article {

  font-family: Calibri;

}

p {

  font-size: 11.0pt;

  margin-top: 4.0pt;

  margin-bottom: 4.0pt;

}

HTML:

<?xml version="1.0" encoding="utf-8" ?>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

  <title>New Topic</title>

</head>

<body>

  <article>

  <p>Sample text</p>

</article>

</body>

</html>

In this scenario, <body> has defined font-family "Arial", but <article> has defined font-family "Calibri". In this case <p> is child of <article> and would inherit the font-family from article, which is "Calibri" here.

Peter GraingeMy thinking is that by not showing a font, or any other property, you are alerting the author to the fact that it is not defined and that the outcome might not be what they want. I get Pierre's point but maybe with that understanding, it's better as is?

Well, to be 100% correct, one could say, RoboHelp is "showing" the user, that these properties are not explicitly declared for the selected element. So, from that perspective, it is 100% okay as it is now, and personally, I think it's good that way. However, Pierre has a point. Right now RoboHelp is VERY strict here. But it makes sense, to also show inherited formatting information and visually indicate that in the properties panel for the value in question. And maybe also warn (e.g. with a red exclamation mark) in case the element in question has this value not defined and also none of the ancestor elements have this value defined as well, as this would be the worst-case scenario and result in a browse fallback. On the other side, this worst-case scenario would be only there if someone has really messed up the CSS and has the needed property not defined for any ancestor element. Hm …

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 30, 2019 0
Community Beginner ,
Apr 30, 2019

Copy link to clipboard

Copied

Hi,

Normally, there is a default Style, Font-Size-Color-Paragraph and it's called Normal.

If you type a simple phrase:

My name is Pierre.

That phrase will use the Normal style. If you change the format of the phrase or part of it;

My name is Pierre.

The Style will remain Normal, but the changes will be accepted only for those caracteres, exactly like in this reply box.

So why is it so complex? Its text and we need to easilly type it, or copy it from where ever, and format it in the Body of the Topic or in a Drop-Down Text box without having to look at the code.

Pierre

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 30, 2019 0
Adobe Employee ,
Apr 30, 2019

Copy link to clipboard

Copied

I guess with "Normal" you are referring to the famous Microsoft Word Document Style "Normal" for "normal" paragraphs?

metaconcert1965  wrote

The Style will remain Normal, but the changes will be accepted only for those caracteres, exactly like in this reply box.

That's the same in RoboHelp: When you select some text within a paragraph and change some property in the Properties panel, RoboHelp will show this property for the selected and manually formatted text there.

metaconcert1965  wrote

So why is it so complex? Its text and we need to easilly type it, or copy it from where ever, and format it in the Body of the Topic or in a Drop-Down Text box without having to look at the code.

No need to look at the code. You can define "global" formatting in the CSS with the visual CSS editor without ever looking at the CSS code. And you can define local formatting overrides in the Properties panel without ever looking at the code.

RoboHelp is a 100% standards-compliant HTML5 and CSS3 editor. RoboHelp strictly follows what is defined in these two standards. One might feel comfortable with the models of these standards or not, and like or dislike these standards, of course, but that's just how the whole web works and every website and browser is based on these technologies.

However, if you prefer to have the HTML base element "p" defined with all possibly allowed values, you can simply go the Visual CSS Editor, define everything as per your needs, and from then on, you will see all of this in the properties panel as well. However, it's good to remember, that CSS means "Cascading Style Sheets". That is, styles "cascade" and one element or class inherits formatting information from its parent or ancestor.

It's all possible and very flexible 🙂

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 30, 2019 0
Adobe Community Professional ,
Apr 30, 2019

Copy link to clipboard

Copied

First let's look at a paragraph. If you apply a style that has the font name or other property set the CSS, when you click in it with no other formatting applied, The General tab in Properties will show that font name. If the style does not have a font family or other property set, it won't show because the setup of your CSS may affect it. That's just the way CSS works, as Stefan has explained. It's easily fixed by setting what you want in the CSS and it's a one off.

Now let's look at when you apply some inline formatting, such as setting a specific word to be bold or whatever. If the style of the paragraph doesn't have a font name declared, then it's the same issue as above. Thus if it's blank for a paragraph it follows it should be blank for a span. However, if the P tag does have a font family declared, then I agree that should show in the General tab. At the moment, if you apply Bold, that shows the icon as selected but it doesn't show the font which will be the same as applied to the P tag unless you override it.

Stefan is agreeing that the inherited font should show for spans so I am sure he will take that forward.

Behind it all though is that if the font is not declared for the style, then there's no certainty that what would be shown in the way you want would be what the user sees.

I hope this clarifies things. As Amber said in another thread, it's a world of strict adherence to the CSS and XHTML rules and whilst it's going to take us all time to adjust, it will be better in the long run.


See www.grainge.org for free RoboHelp and Authoring information.

@petergrainge

Please use the blue Reply button at the top to help me help you. The black Reply link nests replies and they sort out of order.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Apr 30, 2019 1