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

[Bug]: If Bottle name contains "<" the name does not display in the main menu #3106

Open
JordanPlayz158 opened this issue Sep 30, 2023 · 4 comments

Comments

@JordanPlayz158
Copy link

JordanPlayz158 commented Sep 30, 2023

Describe the bug

As the title suggests, the bug is that when you include the "<" character in the Bottle name (not sure of any others with this issue but "|", "=", and ">" seem to be fine displaying in bottle name), in the main menu it displays "Bottle name" (but on the bottle page it displays fine), not a big deal but figured I'd document it.

To Reproduce

Rename a bottle with the "<" symbol included (ex. how I found this, I put the prefix of "DXVK <=2.2 REQUIRED | " in one of my bottle names) and restart (only shows bug after restart)

Example of how the bug looks like
Bottle name: https://cdn.jordanplayz158.xyz/uploads/d5c455cef09c00710f937792c0e4ed8b1409464f.png
Bottle name from Bottles list after restart: https://cdn.jordanplayz158.xyz/uploads/55efedd7fb43888f039c94de5a3b49669f06930c.png

Package

Flatpak from Flathub

Distribution

Nobara 38 (Fedora 38 fork)

Debugging Information

Official Package: true
Version: '51.9'
DE/WM: plasma
Display:
    X.org: true
    X.org (port): :0
    Wayland: true
Graphics:
    vendors:
        amd:
            vendor: amd
            envs:
                DRI_PRIME: '1'
            icd: /usr/lib/x86_64-linux-gnu/GL/vulkan/icd.d/radeon_icd.x86_64.json:/usr/lib/i386-linux-gnu/GL/vulkan/icd.d/radeon_icd.i686.json
    prime:
        integrated: null
        discrete: null
Kernel:
    Type: Linux
    Version: 6.5.5-200.fsync.fc38.x86_64
Disk:
    Total: 12562538496
    Free: 12562382848
RAM:
    MemTotal: 23.4GiB
    MemAvailable: 14.4GiB
Bottles_envs: null

Troubleshooting Logs

17:45:52 (INFO) Bottles Started! 
17:45:54 (INFO) Performing Bottles checks… 
17:45:54 (INFO) Dxvks found:
         - dxvk-2.3
         - dxvk-2.2
 
17:45:54 (INFO) Vkd3ds found:
         - vkd3d-proton-2.10
 
17:45:54 (INFO) Latencyflexs found:
         - latencyflex-v0.1.1
 
17:45:54 (INFO) Runners found:
         - caffe-7.20
         - wine-ge-proton8-17
         - sys-wine-8.0.2
 
17:45:54 (INFO) Bottles found:
         - FoliageVsUndead
         - FNAF World <
 

(bottles:2): Gtk-WARNING **: 17:45:54.288: Failed to set text 'FNAF World <' from markup due to error parsing markup: Error on line 1 char 23: “<” is not a valid name
17:45:54 (INFO) Catalog installers loaded 
17:45:54 (INFO) Catalog dependencies loaded 
17:45:54 (INFO) Catalog components loaded

Additional context

No response

@koplo199
Copy link
Contributor

koplo199 commented Oct 3, 2023

Seems like the set_title() method of Adw.ActionRow breaks if the string contains an "<". It's a GTK/libadwaita bug, not a Bottles one.

@cybin
Copy link
Contributor

cybin commented Oct 26, 2023

As stated in the documentation of set_title(), it is read as a Pango markup string, unless explicit disabled. I guess, it fails due to a non-closed markup element.

https://gnome.pages.gitlab.gnome.org/libadwaita/doc/main/method.PreferencesRow.set_title.html

@JordanPlayz158
Copy link
Author

Hmm, so it is possible for Bottles to fix if they disable Pango markup before setting title?

@cybin
Copy link
Contributor

cybin commented Oct 26, 2023

Yes, I think so. I've edited bottles/fronted/ui/new.blp and it is not complaining any more. It creates the bottle and stores the name correcly in bottle.yml.

          .AdwPreferencesGroup {
            .AdwEntryRow entry_name {
              use-markup: false;
              title: _("Name");

But it is not working any way. It must be set throughout the project and I couldn't find the places where to set it. So, I can create a bottle, but it will not be shown in the list.

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

No branches or pull requests

3 participants