Search Unity

Feedback Wrap text in string table editor

Discussion in 'Localization Tools' started by kork, Jun 19, 2020.

  1. kork

    kork

    Joined:
    Jul 14, 2009
    Posts:
    280
    We're currently doing some text based adventure and we have lots of longer text passages. The text is supposed to be displayed depending on available screen width so we only add newlines when we need a paragraph and when rendering the strings in-game we auto-wrap them according to available width.

    The string table editor currently does not wrap text around automatically, so most of the strings we add are just one huge line of text, which is very inconvenient to edit. It would be super-helpful if the string table editor would auto-wrap the text (or at least have a setting for it).

    upload_2020-6-19_7-40-18.png
     
  2. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    8,282
    Hi,
    The wrapping was actually disabled intentionally but having a setting to enable/disable it makes sense. I'll add it to our list.
     
  3. kork

    kork

    Joined:
    Jul 14, 2009
    Posts:
    280
    Hi Karl, thank you very much. Would you provide some insight about the reasoning behind disabling the wrapping? I mean I'm glad that you add it to the list as a setting, but maybe I'm using this not the way it was intended to be used.
     
  4. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    8,282
    Wrapping can give the impression the text has new lines when it doesn't making it look different when rendered. Of course if the render is doing line wrapping then it's different again ;)
    Making it an option makes sense.
    It has already been brought up by our QA
     
  5. John_Leorid

    John_Leorid

    Joined:
    Nov 5, 2012
    Posts:
    651
    When will this feature be ready?
    It's pretty hard to use the TableEditor right now (but we use it for pretty much everything).
    I'd be fine with changing the setting in a line of code or so.

    I found the code, where it is set, it's inside SmartFormatField.cs Line Nr. 360 - but I can't change it, whenever I press "save" unity will just revert any changes made to the script.

    Also you could do it like Visual Studio does, with a symbol (at the end of the line) when it is wrapped atomatically and no symbol when it is a real NewLine. But a simple toggle on top of the LocalizationTable Editor would be good enough for most use-cases.

    And as I am already talking - Minimizing Entries (Foldout) would also be great, otherwise it's a lot of scrolling up and down, when it could be just a few lines, which can be expanded to full text.

    Otherwise: great asset! Thanks a lot for adding this to unity, ingame it works flawlessly and the customInspector field is also great for assigning localized strings - love it :)
     
    Last edited: Jan 9, 2021
  6. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    8,282
    If you want to make changes to a package, you need to move the package from the package cache folder into your projects packages folder. You will then be able to make changes.
    We have plans to do a rework of the table editor for 0.11