Editor dialogs not remembering table spacing

I’ve noticed that in 5.1.4 that any of the edit dialogs like events don’t remember what the spacing is for columns. Every time I open a dialog, it defaults back to the default spacing. Is there a way to have it remember them?

The list and column spacing have never been remembered between opening edit windows. The major Views; People, Families, Events, Places, Sources, Citations, Repositories, Notes, and Media have configurable columns and will remember the spacing allocated by the user.

You can hack the code to allocate more or less space for the various edit windows. Which dialog windows are you most interested in modifying?

Sorry getting back so late. In event Reference Editor, Source citations, I would like to have the title about 50 percent wider.

I am not sure which list you are referencing but since you mention the Source Title I will make these assumptions.

All files are in the Gramps program code folder. Edit…

\gramps\gui\selectors\selectcitation.py at line 69

def get_column_titles(self):
    return [
        (_('Source: Title or Citation: Volume/Page'), 350, BaseSelector.TEXT, 0),
        (_('ID'),     75, BaseSelector.TEXT, 1),
        (_('Last Change'), 150, BaseSelector.TEXT, 6),

To increase Source: Title…. change the 350 to maybe 450

Likewise, you may want to edit…

\gramps\gui\selectors\selectsource.py at line 64

def get_column_titles(self):
    return [
        (_('Title'), 350, BaseSelector.TEXT, 0),
        (_('Author'), 200, BaseSelector.TEXT, 2),
        (_('ID'), 75, BaseSelector.TEXT, 1),
        (_('Last Change'), 150, BaseSelector.TEXT, 7),

To change the column widths of the Tab that display the list of Citations, edit…

\gramps\gui\editors\displaytabs\citationembedlist.py at line 79

_column_names = [
    (_('Title'),   0, 200, TEXT_COL, -1, None),
    (_('Author'),  1, 125, TEXT_COL, -1, None),
    (_('Page'),    2, 100, TEXT_COL, -1, None),
    (_('ID'),      3,  75, TEXT_COL, -1, None),
    (_('Private'), 4,  30, ICON_COL, -1, 'gramps-lock')

Some pointers…

The program folders are protected so you will need to edit with administrator rights.

When the next version of Gramps comes out, you will need to make these changes again. The main code will not change column sizes based upon display size considerations. So you need to give yourself a way to remember any changes to the code you make.

When editing the code, make sure to not alter indents. They are important.


Remember to log any hacks that you do to the layouts. If you do not submit a feature request tweak to the base code that actually gets rolled into an update, you will have to repeat the hack for subsequent releases.

It is handy to manually renumber the original Note ZERO and keep details about hacks in a NEW Note assigned that ID. This makes finding them easier.

Thanks, I’ll try that.

Can you make a feature request for that. I think I have a solution.


You can see the PR: Column widths in selection dialogs. by SNoiraud · Pull Request #1302 · gramps-project/gramps · GitHub


Great work. This takes care of remembering previous column widths in Selectors.

Can the same be done for the lists under Tabs? It would be a lot of work. Not just the Tabs in Edit windows but if that can be made to work there would also be all the various gramplet tabs.

I don’t see where you want to have this done.
can you attach snapshot of these ?


I offered up changing the Source Citations tab in edit windows to give the Title more space. \gramps\gui\editors\displaytabs\citationembedlist.py

So it would be remembering the space the user allocates under the various Tabs in the edit windows.

Remembering these tabs would be more important than gramplet tabs but it would create the expectation that all lists would be remembered.

Thank you! This seems like it should be very useful for translation… where different languages might need different widths for the data.

I wonder if there would be a way to manage/distribute persistent localized settings?