Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
Next:
badges earned

Your Points Tracker
Challenges
Leaderboard
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Recognition
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Kudos
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Preserve multiple spaces in a row in JIRA issues

In a JIRA issue description, any number of sequential spaces will be collapsed into a single space.

E.g., "this          sentence has 10 spaces between the first two words"

I pressed the spacebar 10 times after typing "this" in that sentence. There should be 10 spaces between "this" and "sentence" but JIRA automatically collapses them into a single space.

None of the style options seems to preserve spaces. I am using JIRA v6.4.12 and the preformatted, paragraph quote, and block quote style options all collapse spaces.

I need to preserve spaces because I often paste stack traces into issue descriptions. The spaces for formatting make stack traces much easier to read.

Is there a way to force JIRA to display spaces as-is?

 

2 answers

1 accepted

3 votes
Answer accepted

Wrap the text in 

{noformat} OR {code}

tags, like so:

this          sentence has 10 spaces between the first two words using {noformat}
this          sentence has 10 spaces between the first two words using {code}

Indeed, it's not JIRA collapsing the spaces, it's HMTL standards being implemented by your browser.  The noformat and code macros tell JIRA to serve up non-breaking spaces instead of plain ones.

Pasting text still removes all extra spaces :(

Like Zachary Kanfer likes this

Solved, switch from visual mode to text using the tab at the bottom of your comment

At comments {noformat} or {code} doesn't work =\

Anyone know how to do it at comments?

{noformat}

    Text

{noformat}

The {code} and {noformat} tags do work for me but I haven't figured out a method for my desired behavior which is simply to get   style whitespace in conjunction with some other formatting like text colors.

It seems to work OK when entering the text manually from the Visual tab but when I programatically submit it via the REST API the whitespace gets collapsed.

In the description field, I'm looking to do something like this:

label one:                 Value1
another long label:  Value2

But even when I use the unicode 0x00A0 (non breaking space) it collapses to this:

label one: Value1
another long label: Value2

When I view the text tab, the multiple white space padding characters are still present... they just render as a single space. 

When using {code} or {noformat} it encloses the content with a big gray block and doesn't support any color or bold formatting within.  I'm hoping to avoid the gray block, use colors, preserve whitespace.

Any ideas?

Tried the {{ monospace }} formatting tags, tried using various flavors of unicode whitespace (0x00A0).

Like Jacob Krch likes this

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Jira Service Management

JSM June Challenge #2: Share how your business teams became ITSM rockstars

For JSM June Challenge #2, share how your non-technical teams like HR, legal, marketing, finance, and beyond started using Jira Service Management! Tell us: Did they ask to start using it or...

203 views 6 7
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you