Ask Your Question

Unable to change default image Anchor Type in Writer

asked 2020-10-21 02:44:53 +0100

Dr. Pb gravatar image

updated 2020-10-21 02:46:05 +0100

This may either be a feature omission or a show destroying bug; but how does one change the default Image Anchor Type in LibreOffice?

The work flow I'm trying to create requires a few hundred images dropped into a document at once to flow, in order, one after the other.

The default option to anchor it "to character" does naff all for me, and stacks all 800 images on top of each other. How useful! eyeroll

But there is no way to CHANGE this behaviour as a default in the application settings, the template settings, even setting the anchor and other image properties and creating a new style from selection does not work, everything ELSE copies over perfectly... except the anchor type.

There doesn't even seem to be a way to select multiple images to change the anchor type in bulk with one click... instead of 800 times.

How the heck do I do this? This was not a problem in older OpenOffice version and is something I did regularly. (Edit: No, I will NOT create a macro for something this asininely simple.)

edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted

answered 2020-10-21 22:20:38 +0100

jkaufmann gravatar image

I hope you noted a work-around discussed in the comments: Pick an instance of the frame style, edit as needed, then use +Update Style (upper-right corner of Styles panel) to force LO to add the anchor type and its attributes to the style. Someday that work-around may not be needed (an enhancement is agreed, but not assigned), but the fact that there is a work-around may explain why the enhancement has low priority.

edit flag offensive delete link more

answered 2020-10-21 08:47:56 +0100

ajlittoz gravatar image

You can't change the default anchor mode. It would certainly be nice to do so and even to store it in a style frame. The anchor is an "instance property" and as such is external to style.

Unless I'm wrong, the default anchor mode is To paragraph (but it does not make a big difference).

A change was introduced in wrap mode. There is now an option called Allow overlap. Determine which frame style is used for your pictures (click on one and look in the style side pane on the frame styles list). Modify this frame style, Wrap tab to remove the overlap option.

You may then need to Tools>Update>Update All to see the change.

Since I have no such file, I can't check if this will cure the problem because a frame can't be positioned on another page than its anchor.

I feel however that there is a flaw in your workflow. Pasting 800 pictures at the same location means all 800 have equal meaning and do not matter individually, they are replacements for each other. Their sequence order is also unimportant. Eventually, edit your question or add a comment (answers are reserved for solutions) to explain what you want to do with your pictures; Writer may not be the best tool for your purpose.

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


Allow overlap since LibreOffice 6.4.

LeroyG gravatar imageLeroyG ( 2020-10-21 14:58:02 +0100 )edit

"The anchor is an "instance property" and as such is external to style."

But other instance properties are inherited from style properties, aren't they? Do you know what is different about the anchor?

jkaufmann gravatar imagejkaufmann ( 2020-10-21 19:09:19 +0100 )edit

I have no idea for the reason of this design decision. Apparently, the same frame style may be applied to many pictures (or more generally frames) with various anchors. Shame because this means you must set the anchor mode individually. I can understand that for To character because anchoring to a specific character is very tricky, unstable and reverts easily (unexpectedly often) to To paragraph. But I don't see any rationale for the other modes.

ajlittoz gravatar imageajlittoz ( 2020-10-21 19:28:22 +0100 )edit

Thank you, sincerely; you are such a treasure of information.

This seems such a sensible and obvious thing to do that I checked bugzilla, and found it has been under discussion for the past decade in Bug#32484 (and apparently for the decade before that in OO), but remains unassigned. The bottom line is that ODF allows anchor-type as an attribute of the object and of the style, but LO implements only the object. [No hard reason for that is given.]

However, there is a work-around noted in Bug#32484 Comment 2: Pick an instance of the frame style, edit as needed, then use +Update Style (upper-right corner of Styles panel) to force LO to add the anchor type and its attributes to the style. I tried, and that seems to work. Far from ideal, but the fact that there is a work-around may explain the low priority for this obvious issue.

jkaufmann gravatar imagejkaufmann ( 2020-10-21 21:31:09 +0100 )edit

The workaround does not work on my xubuntu machine (LO Does the anchoring change really work for you when updating the style???

I also tried to tweak the styles.xml file and strangely, the anchor type setting of a pic added after that change is just char instead of as-char as modified in styles.xml.


Hagar Delest gravatar imageHagar Delest ( 2020-11-14 18:35:07 +0100 )edit

@Hagar Delest: anchor mode is not part of the frame style. Consequently, it should not change when you modify your frame style.

ajlittoz gravatar imageajlittoz ( 2020-11-14 19:03:39 +0100 )edit

Then I don't understand jkaufmann's comment above about adding the attribute to the style.

Note that I managed to have this change remain in AOO. Will try to investigate the difference.

Hagar Delest gravatar imageHagar Delest ( 2020-11-14 21:13:54 +0100 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2020-10-21 02:44:53 +0100

Seen: 38 times

Last updated: Oct 21