# HUD:DrawText, Newlines \\n no longer cause a return, get box instead, Canvas::DrawText also has issues

**URL:** <https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine\
**Created:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490 "2014-03-11T02:23:28Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![ue4-archive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ue4-archive](https://forums.unrealengine.com/u/ue4-archive)\
**Post date:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/1 "2014-03-11T02:23:28Z")

</div>

![newlinesdrawtext.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/1/5/415ec6b8a42e7f05a9108d992d0b5cd7b40a1230.jpeg)

Dear Friends at Epic,

#Bug

In Beta4, using draw text on a string like “Joy\nJoy\nJoy\n” would result in

```
Joy
Joy
Joy

```

#Video For Reference

You can see in this video how my exact same code behaves now in Beta5 vs in Beta4

~~~

In Beta5, the newlines are replaced with boxes, and everything stays on a single line

I deem this a bug because it requires more work of me to actually parse the string manually now

Very inconvenient in my opinion

Again this is **HUD::DrawText()**

#Canvas::DrawText

 ![canvas.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/5/8/0589052b6e426e07eb01432102169ab2706e4d86.jpeg)

Canvas-\>DrawText actually does do the returns, but it also draws the newlines as boxes,

**this still requires me to parse out the newlines manually which I never had to do before**

_I can only call this a bug or a very inconvenient change_ 🙂

**I am loving UE4 tho! It’s awesome!**

Rama

---

<div class="post-metadata">

**Author:** ![ue4-archive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ue4-archive](https://forums.unrealengine.com/u/ue4-archive)\
**Post date:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/2 "2014-03-11T02:23:29Z")

</div>

#Packaged Multiplayer Game Video

This is a video showing that actual real Multiplayer works via IP with the **packaged version** of my game!

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/5/f/05fbb84d14309af0fbde5aa81c557bd401b0ea20.jpeg "Multiplayer Testing Fun") ](https://www.youtube.com/watch?v=xy7ay_-tFlk)

In the video I did end up having to parse out the strings for the chat system, given the situation I am describing in this thread

Rama

---

<div class="post-metadata">

**Author:** ![ue4-archive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ue4-archive](https://forums.unrealengine.com/u/ue4-archive)\
**Post date:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/3 "2014-03-11T02:23:29Z")

</div>

We filed a report for this issue, and it has already been resolved internally. Once again, thanks for having brought it to our attention.

Cheers!

---

<div class="post-metadata">

**Author:** ![ue4-archive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ue4-archive](https://forums.unrealengine.com/u/ue4-archive)\
**Post date:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/4 "2014-03-11T02:23:30Z")

</div>

woohoo!

Thanks for letting me know Stephen!

🙂

Rama

---

<div class="post-metadata">

**Author:** ![ue4-archive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ue4-archive](https://forums.unrealengine.com/u/ue4-archive)\
**Post date:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/5 "2014-03-11T02:23:30Z")

</div>

#Packaged Multiplayer Game Video

This is a video showing that actual real Multiplayer works via IP with the **packaged version** of my game!

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/5/f/05fbb84d14309af0fbde5aa81c557bd401b0ea20.jpeg "Multiplayer Testing Fun") ](https://www.youtube.com/watch?v=xy7ay_-tFlk)

In the video I did end up having to parse out the strings for the chat system, given the situation I am describing in this thread

Rama

---

<div class="post-metadata">

**Author:** ![ue4-archive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ue4-archive](https://forums.unrealengine.com/u/ue4-archive)\
**Post date:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/6 "2014-03-11T02:23:30Z")

</div>

Thanks for the report.

I’m not certain yet why this changed, but I’ve put a bug report in to our system to investigate and determine whether it was intentional or not. I will say that from looking at the code. From a cursory inspection of the code I don’t actually see what was doing the line feed previously.

---

<div class="post-metadata">

**Author:** ![ue4-archive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ue4-archive](https://forums.unrealengine.com/u/ue4-archive)\
**Post date:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/7 "2014-03-11T02:23:31Z")

</div>

Great to hear from you as always Marc!

**Thanks for all your help!**

🙂

Rama

PS: yea I always thought it was extremely convenient and magical that the \n worked previously 🙂 it worked in UE3 too, I had basically copied my code over from my ue3 chat system.

---

<div class="post-metadata">

**Author:** ![ue4-archive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ue4-archive](https://forums.unrealengine.com/u/ue4-archive)\
**Post date:** [March 11, 2014, 2:23am UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/8 "2014-03-11T02:23:31Z")

</div>

#Corollary in BP Descriptions

I have more info on this issue

**Whatever was causing \n to be turned into actual newlines / returns**

was also working on the BP node comments

**and now that is gone too!**

In beta4 I spent a lot of time adding \n\n to my longer BP node comments in my BP function library

but now in beta5 these \n show up directly just like in HUD

so wherever \n used to get turned into an actual newline is probably at some higher level than just the HUD

 ![nomorereturnsinbpcomments.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/4/0/34082ca36204d8aa39197d5e83d552f82fa74216.jpeg)

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_4071fa6e1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_4071fa6e1](https://forums.unrealengine.com/u/anonymous_user_4071fa6e1)\
**Post date:** [August 27, 2014, 1:53pm UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/9 "2014-08-27T13:53:04Z")

</div>

→ _We filed a report for this issue, and it has already been resolved internally._

Was there a resolution back in March or was it still problematic?

I am using 4.4 and DrawText/Append are still unable to handle newlines.

I have [asked](https://answers.unrealengine.com/questions/78437/blueprint-drawtext-append-string.html) about this before but received no response.  
Thanks.

---

<div class="post-metadata">

**Author:** ![Rama](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/rama/32/882413_2.png) [@Rama](https://forums.unrealengine.com/u/Rama)\
**Post date:** [August 27, 2014, 1:58pm UTC](https://forums.unrealengine.com/t/hud-drawtext-newlines-n-no-longer-cause-a-return-get-box-instead-canvas-drawtext-also-has-issues/275490/10 "2014-08-27T13:58:34Z")

</div>

I second this, and newlines still don’t work in BP comments either!

```
/** Some comment with a newline \nMore Text */
UFUNCTION()
```
