Join minus symbol to number, chain characters

Temperature is -30°C somewhere (Writer, within line) {NL new line}

Temperature is -
30°C

Temperature is {NL}

-30°C (Writer, what belongs together stays together - appears not supported in Writer {NL}

I hope software does not garble layout. It does, {NL new line} added.

(formatting modified by ajlittoz, hoping not to have betrayed OP’s inention)

And there is usually a space between the number and the unit of measure. So you will need to add a non-breaking space before °C.

The behaviour comes from the use of HYPHEN-MINUS U+002D whose primary usage in document processing applications is to indicate a hyphen. Application is free to cause line wrap after the hyphen, as if a long word had been hyphenated.

When you really mean a minus sign with its mathematical semantics, you should use MINUS SIGN U+2212 which is specifically reserved for its numeric meaning. Usually the shape of the glyph is slightly different from the hyphen (wider than the latter) so that you can visually notice the difference.

If you are reluctant to enter a character not commonly present on keyboards, you can also enter a ZERO WIDTH JOINER U+200D after the minus-hyphen with Insert>Formatting Marks>No-width No Space.

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!

In case you need clarification, edit your question (not an answer which is reserved for solutions) or comment the relevant answer.