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

Hide schema editing menu and tabs #5159

Open
marcpley opened this issue Dec 9, 2024 · 19 comments
Open

Hide schema editing menu and tabs #5159

marcpley opened this issue Dec 9, 2024 · 19 comments
Labels
data-mode-plugin Issues intended for the "Date Only mode" that @marcpley is taking care of

Comments

@marcpley
Copy link

marcpley commented Dec 9, 2024

In order to have a data only mode, add an option to hide menu Structure and tab selection.

image
Add checkbox "Hide schema editing menu and tabs"

@marcpley
Copy link
Author

marcpley commented Dec 9, 2024

The Structure menu could be visible and inactive. I think it would be more comprehensible for the user.
The tab selector could be not visible instead of sowing a single Data tab. This spare vertical room for the data.

@pawelsalawa
Copy link
Owner

I think all settings for the "data only mode" that you're aiming here should be placed on a dedicated page tab in Configuration Dialog, like - for example - ScriptingPython plugin does in 3.5.x:
image
...or similarly does the "SQL enterprise" formatter plugin.

Since plugin will implement/handle all these settings, they should be on its dedicated page.

As for the functionality - I guess hiding the structure menu (and structure toolbar too) is fine. Keeping it visible if it's intended to be disabled all the time does not make much sense - it only keeps the UI more "noisy" in that case.

Hiding table tabs other than "Data" is possible, but it will require to connect to signals of MDI area instance, to handle events of opening TableWindow and hiding the tabs.

@pawelsalawa pawelsalawa added the data-mode-plugin Issues intended for the "Date Only mode" that @marcpley is taking care of label Dec 9, 2024
@marcpley
Copy link
Author

marcpley commented Dec 9, 2024

Does the export/import settings will deal with plugins params too ?

@pawelsalawa
Copy link
Owner

pawelsalawa commented Dec 9, 2024

No. The settings import/export will be part of core functionality of the app.

@marcpley
Copy link
Author

Arghhh

@pawelsalawa
Copy link
Owner

?

@pawelsalawa
Copy link
Owner

I meant #5106 will be part of core functionality. Did you understand something else?

@marcpley
Copy link
Author

marcpley commented Dec 10, 2024

I didn't correctly understand how plugins works. So I don't know what could be possible or not with plugins.

After settings importation I would have the data mode plugin ON with specific parameters, not the default parameter.s

@pawelsalawa
Copy link
Owner

Settings import/export is more for cases when people (for various unknown reasons) are unable to use the application anymore. For example it happens sometimes that someone upgrades SQLiteStudio version and suddenly it no longer works, but it's fine if they rename settings file. This means some particular setting is causing crash for them. In that case it makes sense to be able to import Functions, Collations, Database List - from old configuration, while skipping the core settings (style, fonts, colors, etc), which is most likely responsible for the crash.

For your needs I would recommend creating sqlitestudio-cfg directory next to the SQLiteStudio.exe - in that case SQLiteStudio will store its configuration there. Then you can just distribute this directory alongside of the SQLiteStudio itself and if someone runs it with your sqlitestidio-cfg located next to their SQLiteStudio.exe - they will use your copy of settings.

@pawelsalawa
Copy link
Owner

This sqlitestudio-cfg is described at https://github.com/pawelsalawa/sqlitestudio/wiki/Configuration_directory_location (at the bottom).

@marcpley
Copy link
Author

Does the plugins params are in sqlitestudio-cfg too ?

@marcpley
Copy link
Author

I create the dir /opt/SQLiteStudio/sqlitestudio-cfg (linux) but it stay empty afer running and closing SQLiteStudio...
How this dir is more portable than settings3 file ?

@pawelsalawa
Copy link
Owner

Is your SQLiteStudio executable that you run /opt/SQLiteStudio/sqlitestudio?

@pawelsalawa
Copy link
Owner

(and yes, plugins settings/params will be stored in that file too)

@marcpley
Copy link
Author

Yes I run /opt/SQLiteStudio/sqlitestudio

@pawelsalawa
Copy link
Owner

Is /opt/SQLiteStudio/sqlitestudio-cfg writable by the user that runs SQLiteStudio?

@marcpley
Copy link
Author

No, install is for all users.
This one is vritable
/home/marc/.config/SalSoft/SQLiteStudio
I create sqlitestudio-cfg in /home/marc/.config/SalSoft/SQLiteStudio but it stay empty after run and close of SQLiteStudio.

@pawelsalawa
Copy link
Owner

/home/marc/.config/SalSoft/SQLiteStudio will not be treated as portable.

The sqlitestudio-cfg can be placed either next to the executable binary, or (and this is a chance for you) in the folder from which you start SQLiteStudio. If you start it from terminal - you will always know where is your current directory. If you start from "menu start icon", then probably the working directory is your home directory.

Summing up - I recommend you to create /home/marc/sqlitestudio-cfg and see if that works.

@marcpley
Copy link
Author

It works with /home/marc/sqlitestudio-cfg
Creating a dir here is a bit excessive! But the folder from which start SQLiteStudio opens possibilities.
Anyway, if I create a specific app, this is less important.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data-mode-plugin Issues intended for the "Date Only mode" that @marcpley is taking care of
Projects
None yet
Development

No branches or pull requests

2 participants