OtterBrowser / otter-browser

Otter Browser aims to recreate the best aspects of the classic Opera (12.x) UI using Qt5
https://otter-browser.org
GNU General Public License v3.0
1.8k stars 277 forks source link

[FreeBSD] Using a compose key in Otter #401

Closed beastie1 closed 10 years ago

beastie1 commented 10 years ago

Good day!

In QupZilla (compiled against Qt4), as well as all other non-Qt-based applications (e.g. Gtk+ and Open Motif), I'm able to use a compose key successfully. In Otter, I only get the separate keys, e.g. 'a, instead of á or =e, instead of . So every time I want to write non-conventional characters, I have to use a third-party editor and then copy the text to Otter.

Can this be implemented in Otter, or is it an upstream issue affecting Qt 5x only?

Emdek commented 10 years ago

Works fine here, using both Qt 5.2.1 and 5.3.1, maybe it's issue specific to your platform. Could you please try some Qt SDK examples (like code editor or application examples - available from start page of QtCreator, after searching for editor) to confirm that?

beastie1 commented 10 years ago

I'm using Qt 5.2.1 on FreeBSD. Since it works on everything else, including Qt4, I thought it was weird, which is why I opened this issue. Maybe it's precisely on Qt5 that it doesn't work.

I can't really get the SDK as it's too big to build on my system. But I tested some random code and the compose key doesn't work there either. So I guess it's not Otter's fault.

Emdek commented 10 years ago

@beastie1, please post more possibly useful information about your system and desktop environment, I'll report this issue upstream.

beastie1 commented 10 years ago

FreeBSD 9.1 for i386 No desktop environment, just fvwm Qt 5.2.1 (official FreeBSD package) WebKit Backend 538.1

beastie1 commented 10 years ago

I don't know if this relates somehow to the compose keys or not, but when running Otter from the console, I get multiple errors like:

Qt Warning: Could not find a location of the system's Compose files. Consider setting the QTCOMPOSE environment variable.

Emdek commented 10 years ago

@beastie1, I guess that it is relevant. ;-)

beastie1 commented 10 years ago

Yay, it ẃøṙķß fine now!

I found all the boring stuff in qtablegenerator.cpp. FreeBSD uses the path /usr/local/lib/X11/locale, which is hardcoded in qtablegenerator.cpp, but it doesn't work. It only works if I set the environment variable.

Emdek commented 10 years ago

Reported upstream: https://bugreports.qt-project.org/browse/QTBUG-40115

beastie1 commented 10 years ago

Thank you! :)

Emdek commented 10 years ago

@beastie1, someone replied, with questions:

1) Have you tried to debug this? 2) What is the contents of /usr/local/lib/X11/locale directory on the failing FreeBSD system?

beastie1 commented 10 years ago

Yes I saw the reply during the day, but I wasn't home.

The contents of this directory can be found in this package The package contents mimic the system's hierarchy, so you can just browse the relative path ./usr/local/lib/X11/locale

Note that QTCOMPOSE is being set to the extact same path with QTCOMPOSE=/usr/local/lib/X11/locale export QTCOMPOSE.

Emdek commented 10 years ago

@beastie1, thanks, propagated.

Emdek commented 10 years ago

@beastie1, there was another reply, I guess that it would be best if you would reply there directly.