Ask Your Question
0

Unable to apply URL Internet Link style

asked 2019-03-28 21:48:32 +0200

Cyberglot gravatar image

Hi, I'm using LO on Win 10, Surface Pro 4. My document is 7-pages, containing text, images, footers, and URLs. I've styled all pages and paras.

Something I must have done now prevents me from changing the style of new and existing URLs to the correct URL style. E.g. - I write a sentence such as: "Go to link". - I highlight the sentence, then call up the styles menu, and click on 'Internet Link' (red text and underline). The text turns to blue and I get a red underline. - I delete (Ctrl X) then paste as unformatted text, click on "Internet Link' style. The same blue/red style is applied. - I clear 'Direct formatting' and repeat the above. Same problem. - I go into the styles dropdown, right click on 'Internet Link' style, and click on Modify. The style is correctly set up. Nothing to do. - I create a new style with red font and red underline. Apply the style, but still I get the unwanted blue text. - I check the 'Followed' or 'Visited' link style, but this is also red text with a red underline, so I'm not clicking on the wrong thing.

  1. What's the problem (What style setting have I inadvertently fixed into LibreOffice)?
  2. How can I get back to the default 'Internet Link' style?

I've spent hours on this. Any help much appreciated. Thx, Cyberglot.

edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted
0

answered 2019-03-29 08:08:22 +0200

ajlittoz gravatar image

updated 2019-04-08 11:27:22 +0200

What you experience is related to special properties of Internet Link character style.

Read my answer to question Use another style for links.

EDIT 2019-04-08

You must first throughly understand style hierarchy:

  • lowest priority: paragraph style
  • character style
  • Internet Link or Visited Internet Link (implicitly added by LO Writer)
  • highest priority: direct formatting

There is also the way overriding attributes are handled in the layers. Every style attribute has n+1 states: the n obvious ones -- e.g. checked/unchecked for toggling attrs (2 states), font variants like roman, italic, bold, bold italic (4 states in this examples), font size (many states) -- and a technical one "transparent". Whenever you manually act on an attribute, you create an overriding state. For example, unchecking a box creates a clear overriding state taking precedence on the parent/lower style. The fact that the box is unchecked does not mean the value in the parent/lower is used. To revert to the parent/lower value, the attribute must be reverted to "transparent" with the Standard button. Beware that the button reverts all atributes in the currently displayed tab to "transparent", so you need to reset the needed overrinding attrs.

In your case, you must proceed in an orderly fashion because it is very difficult to manually apply several styles to the same chunk (and presently not reommended to try).

Start by returning your document (at least only the paragraphs containing bookmarks and links) to a clean initial state by removing all direct formatting (direct formatting should be avoided whenever you work with styles; you even have no visual clue that direct formatting has been applied) and character styles. The URLs should still be formatted Internet Link. Make sure all URLs are recognised as such. If some are not, erase them and retype them in order to get the correct hyperlink attribute (Writer will add Internet Link character style).

Define character styles: the one for bookmark and customise Internet Link and Visited Internet Link paying special attention to the hierarchy described above and the "transparent" attribute state in the top styles, Internet Link and Visited Internet Link so that the lower attributes are visible through the top styles.

When done with styles, select your bookmarks, eventually your URLs and style them with the bookmark character style. This will add the style "between" paragraph style and Internet Link.

If you do it the other way round, i.e. the bookmark style first, then Internet Link, you end up only with Internet Link* becuse you can manually only add one style. Every manual addition replaces the previous manual addition. The tricky URL formatting relies on the implicit Internet Link formatting by Writer.

If you still don't succeed, attach your file or a sample of it.

To show the community your question has been answered, click the ✓ next to the correct answer, and "upvote" by clicking on the ^ arrow of any helpful answers. These are the mechanisms for communicating the quality of the Q&A on this site. Thanks!

edit flag offensive delete link more

Comments

Thanks for reading my message. I've read your answer (linked) and tried over several hours and days to get this to work, but regrettably I've failed. It would be a very long message if I were to explain what I've tried, but an example of odd behaviour that you may be able to respond to is: 1. I follow the instructions in your earlier solution, then highlight the text in the document representing the Internet hyperlink, apply my new style and... the selected text does not change, but the rest of the paragraph changes to the new style. I appreciate your time on this. Regards, Cyberglot.

Cyberglot gravatar imageCyberglot ( 2019-04-01 23:11:26 +0200 )edit

A naive question: the styles alluded to in my answer are character styles. Your description of the mishap suggests you used a paragraph style. Please check.

ajlittoz gravatar imageajlittoz ( 2019-04-02 08:33:31 +0200 )edit

10th April, 2019. Hi, I can't see any 'Reply' button or means of responding to your suggestion, so am writing here. This is a reply to your suggestion EDIT 2019-04-08

I've understood the layer approach of styles and have followed your instructions, but I can't solve the problem. I've even created a new document, copied a page of the old one into it (with URLs), and followed your instructions again, but still no progress. I'd like to attach the sample page, but can't see an "Attach" button or paperclip icon.

Thanks for your time on this. I hope the thread helps other readers, too. Rgds, Cyberglot.

Cyberglot gravatar imageCyberglot ( 2019-04-09 23:26:36 +0200 )edit

This is the right place to comment or otherwise "reply" to answers and comments.

To attach a file, edit your question. In the small toolbar, there is a paper clip (7th icon from left). If you bump into a karma points limit (though it has been changed recently), post a link on some third-party upload service.

ajlittoz gravatar imageajlittoz ( 2019-04-10 07:57:21 +0200 )edit
0

answered 2019-04-08 00:04:09 +0200

Cyberglot gravatar image

Thanks for your reply. Ran out of space in the comments box, so am replying here. It's likely the example I gave is a result of my error (again!), so thanks for pointing that out, but I've been running through a number of procedures to remove / add / modify styles on links using character styles, and I still can't achieve what's required. Here's another example:

There are URLs and bookmarks in the doc. 1. Currently, bookmarks and URLs use the same style: Internet_Link (character). 2. These links are an unwanted mix of red and underlined, green and bold, or plain body text char. I want to get all URLs (unvisited) red and underlined, and bookmarks green and dotted underlined. 3. I highlight one of the URLs in the doc, then highlight the 'Internet Link' style (character) list with F11. The 'Internet Link' style is displayed as yet another format combination (i.e. not red, green or underlined, just body text font). 4. I try clicking on standard to return the style to its default setting. This changes nothing. 5. I click on 'Clear direct formatting'. This returns the URL link to the default style (black text, no underline). Fine. I then click on Internet_Link, modify this to red font, red underline, double-click and... 6. ... the URL text does turn red, but there's no underline, and all bookmarks turn red and with underline.

I'm frustrated beyond description, so any comments would be much appreciated.

Thanks in advance, Cyberglot.

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2019-03-28 21:48:32 +0200

Seen: 5,088 times

Last updated: Apr 08