Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Win32 UI frontend: Localized multi-line strings aren't displayed correctly (was: Line feeds not working in descriptions for GameCube titles with BNR2 banner) #416

Closed
rctgamer3 opened this issue May 19, 2024 · 5 comments
Assignees
Milestone

Comments

@rctgamer3
Copy link

Tested with: Wind Waker (EU) (98f0a19d9a3b2ca3352621c77f47a547c97a27f1)
BNR format: BNR2

Description sample:

Tragedy strikes a peaceful island,
and the Legend of Zelda begins anew!

Raw data from bnr:

5472616765647920737472696B657320
6120706561636566756C2069736C616E
642C0A616E6420746865204C6567656E
64206F66205A656C646120626567696E
7320616E657721

Note that it contains a LF (0A) in the text on the third line. It works fine for a BNR1 / US banner.

@GerbilSoft
Copy link
Owner

GerbilSoft commented May 19, 2024

I'm not seeing the issue on Linux. (Currently building the Windows version on a VM to check if it's a Windows-only problem.)

Both the rpcli and KDE GUI views look correct here.

rpcli text:

== Reading file 'GZLP01.bnr'...
-- Nintendo GameCube Banner File detected
Game Name:   'The Legend of Zelda: The Wind Waker'
Company:     'Nintendo'
Description: 'Tragedy strikes a peaceful island,
              and the Legend of Zelda begins anew!'
-- Internal banner is present (use -x1 to extract)
   Format : ARGB32
   Size   : 96 x 32

rpcli json (only the relevant section):

{
  "type": "STRING_MULTI",
  "desc": {
      "name": "Description",
      "format": 0
  },
  "data": {
      "de": "Eine friedliche Insel wird plötzlich von einer\nKatastrophe heimgesucht...",
      "en": "Tragedy strikes a peaceful island,\nand the Legend of Zelda begins anew!",
      "es": "Una pacífica isla es sacudida por la tragedia\ny la Leyenda de Zelda comienza de nuevo.",
      "fr": "Soudain, sur une île paisible, la tragédie s'abat\net ranime une fois encore la Légende de Zelda!",
      "it": "Una sventura turba la pace dell'isola Primula.\nCosì ricomincia la leggenda di Zelda."
  }
}

@GerbilSoft
Copy link
Owner

GerbilSoft commented May 19, 2024

Reproduced it on the Windows GUI, and I'm pretty sure that's just a general limitation of the Win32 UI frontend not being able to show multiple lines at the moment. Will take a look at setting ES_MULTILINE and resizing the control to fit multiple lines.

@GerbilSoft GerbilSoft changed the title Line feeds not working in descriptions for GameCube titles with BNR2 banner Win32 UI frontend: Multi-line strings aren't displayed correctly (was: Line feeds not working in descriptions for GameCube titles with BNR2 banner) May 19, 2024
@GerbilSoft GerbilSoft self-assigned this May 19, 2024
@GerbilSoft GerbilSoft added the bug label May 19, 2024
@GerbilSoft GerbilSoft added this to the 2.4 milestone May 19, 2024
@GerbilSoft GerbilSoft changed the title Win32 UI frontend: Multi-line strings aren't displayed correctly (was: Line feeds not working in descriptions for GameCube titles with BNR2 banner) Win32 UI frontend: Localized multi-line strings aren't displayed correctly (was: Line feeds not working in descriptions for GameCube titles with BNR2 banner) May 19, 2024
@GerbilSoft
Copy link
Owner

...and now I just verified that it does in fact work with BNR1, but not BNR2. It's an issue with the RFT_STRING_MULTI (localized string) functionality specifically.

@GerbilSoft
Copy link
Owner

New build will be available here: https://ci.appveyor.com/project/GerbilSoft/rom-properties/builds/49844116

Please test once it's available (or compile it yourself) and let me know if this fixes the problem on your side.

@rctgamer3
Copy link
Author

Displays fine with multiple lines with the test build above!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants