orbitalquark / textadept

Textadept is a fast, minimalist, and remarkably extensible cross-platform text editor for programmers.
https://orbitalquark.github.io/textadept
MIT License
659 stars 39 forks source link

Textadept does not adhere to the theme that KDE Plasma applies to GTK. #199

Closed RokeJulianLockhart closed 1 year ago

RokeJulianLockhart commented 2 years ago

The window remains white despite my configuration of the appearance of GTK hopefully preventing any alternative software appearing to be differently coloured. Is this because Textadept does not install via my package-manager?

orbitalquark commented 2 years ago

Textadept 11.3 and earlier uses the GTK 2 toolkit. I suspect either KDE is not setting the GTK 2 theme, or there is no GTK 2 compatible version of the GTK 3 theme KDE is setting. Check if your package manager has a package for GTK 2 theme compatibility.

Textadept 11.4, when it is released, will use GTK 3, so this issue should go away.

RokeJulianLockhart commented 2 years ago

@orbitalquark, you intend to replace GTK3 with GTK4 soon? GTK3 is 1 version previous to what is the most new.

orbitalquark commented 2 years ago

No, not soon.

orbitalquark commented 2 years ago

Textadept 11.4 has been released, and it uses GTK 3 by default. Hopefully this issue has gone away. Closing ticket.

RokeJulianLockhart commented 2 years ago

Indeed, @orbitalquark, although that appears to have improved the titlebar and contextual menus, this demonstrates that the editor of https://github.com/orbitalquark/textadept/releases/download/textadept_nightly/textadept_nightly.linux.tgz remains white.

rgieseke commented 2 years ago

This looks like Textadept's regular default light theme in the editing area. The user interface theming for menus etc. is separate from Textadept's theme. It ships with a dark theme and there a bunch at https://github.com/rgieseke/base16-textadept/ which might better match the rest of the system's style.

RokeJulianLockhart commented 2 years ago

However, I don't need custom colouration for solely one section of one application. I am uncertain of why that might be desirable. The theme that I utilize for my system is what I want to utilize for everything.

Additionally, I am unable to suggest this to my family or acquaintances if it doesn't adhere to their themes, because they don't care either; they shall want it to “just work”.

rgieseke commented 2 years ago

Fair enough, but i think most editors work like that since it would be difficult to have code to read every OS/desktop's theming and use that in the editing area (at least for the cross-platform editors).

RokeJulianLockhart commented 2 years ago

@rgieseke, all that it needs to do is not theme the native controls unless custom colouration is deliberately applied.

rgieseke commented 2 years ago

I think that's what it does, on Linux at least, the GUI controls get styled from the system, the editor pane is handled by the Scintilla engine Textadept uses and is styled separately.

paaguti commented 2 years ago

Which is, BTW not different from other editors like Emacs do ;-)

On Tue, 6 Sept 2022 at 18:20, Robert Gieseke @.***> wrote:

I think that's what it does, on Linux at least, the GUI controls get styled from the system, the editor pane is handled by the Scintilla engine Textadept uses and is styled separately.

— Reply to this email directly, view it on GitHub https://github.com/orbitalquark/textadept/issues/199#issuecomment-1238371283, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAZKU4F5HAGXN3FOGL7VL5LV45VNTANCNFSM5V7EW3OA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

-- Fragen sind nicht da um beantwortet zu werden, Fragen sind da um gestellt zu werden Georg Kreisler

Headaches with a Juju log: unit-basic-16: 09:17:36 WARNING juju.worker.uniter.operation we should run a leader-deposed hook here, but we can't yet

RokeJulianLockhart commented 2 years ago

@rgieseke, http://sourceforge.net/p/scintilla/bugs/2350

orbitalquark commented 2 years ago

Sorry for the late reply. The responsibility lies with Textadept in this case, not Scintilla. The editor does not attempt to read the system's color theme (I wouldn't know where that is for a given desktop environment). At the moment, you'll have to call ui.set_theme('dark') or with an appropriate dark theme, such as one from the list mentioned by @rgieseke.

I did not realize you were also referring to the main editing component in addition to the GUI widgets. The original post implied it was just a GUI widget issue with GTK, not Scintilla.

RokeJulianLockhart commented 2 years ago

@orbitalquark, thanks for the response. I expect that that means that the issue needs to be reopened, or at least closed as not planned (hopefully not).

Additionally, if the issue lies with Textadept, should I close the mentioned issue? If you read the responses to it, the developers appear to believe that it affects them, too.

orbitalquark commented 2 years ago

You are correct, we can re-open this and I'll look into it when I have some time.

orbitalquark commented 1 year ago

The next nightly version of Textadept should support auto-detecting and auto-switching between light and dark themes on Linux: https://github.com/orbitalquark/textadept/commit/2fd8e565fe42e50920113c96964939578671363d. I tested on Kubuntu, switching between light and dark Qt themes, and then changing between light and dark GTK themes.

If you have any view:set_theme() calls, please either remove them or adjust them so that they are not passing a theme name (which will override auto-detection).