Experimental Person Profile View Plugin

I have been toying around with an experimental Person Profile View plugin and it is far enough along I thought I would share it publically now although it is still under development. This started as a Gramplet to teach myself how to work with Gtk and learn some more about the Gramps codebase. It is my hope it might be easier to navigate for newer Gramps users and is obviously inspired by the presentation layer of many of the online sites.

For those who might be interested in giving it a spin you can find it over at GitHub

Suggestions for features and other feedback welcome. I will eventually look into making it an official add-on.

I am trying to make it as customizable as possible for those with different display sizes and tastes so you can tailor it to do this for example:

Or for smaller displays something more compact like this:

9 Likes

This is great, thank you for sharing! I see there are quite a few configuration options to explore.

Interesting! love the high visibility of ages in the ‘Large’ version … but it makes for a lot of words to wade through. Would you consider a compact form of the Age format? like “11y2m14d”

Amazing to see Events in the timeline for a Step-family… and Grand too! How far does your timline reach out into extended family? Or past the central person’s Birth & Death? (Will have to look for the Burial and probate stuff!)

So the color coding is Gender based plus green for self Person & Events? (Could use the Green card to mark ‘self’ in the Spouses and Children) The Green cards make the top card a bit superfluous. You could buy back some screen space there.

Also, since Relationships has been the only place you could add a Partner, it is nice that you have Toolbar icons for Add Parents, Share, Add Partner on this screen. Perhaps you can Add Child, Add Sibling that are dimmed if there are more than 1 set of Partner, Parents? (Zero could create a family)

Have you discovered how to let it accept an object dropped on one of the panels? It would be fantastic to drop a Citation (or Place!!!) onto an event and have that freshen without another dialog spawning. Or to drop a Sibling/Child/Parent into those relationships. Or to Drop a census onto a series of family members. (Although those would means having a Role & Relationship presets switch somewhere to avoid popping-up window after window.)

Please tell me that you’ve made the IDs hotlinked (without changing focus) to bring up the appropriate editor for Person, Family, Event, Citation. (Family in particular! I hate the clutter of Edit buttons everwhere in the other views.)

1 Like

I could add that as an option.

It is configurable but I set reasonable limits obviously. It will be used in a FamilyView and perhaps elsewhere at some point. A FamilyView will be sort of similar but timeline will include events for all members of the family from birth to death. Probably information overload but why not. You can pick and choose relations to include to a point and the events for those relations. Birth and death are defaulted and always present when including relations.

For persons and families it uses the Gramps default colors. In config options I support a relation color scheme for the timeline and confidence color scheme for citations. Eventually you be able to pick from default Gramps, relation or event based schemes for the timeline. I am not a graphic artist, if anyone has suggestions for better defaults for those I would really appreciate the help.

All frames have a context sensitive action menu with a right click for performing actions like that, tagging or untagging, making private and opening editor.

No I have not experimented with drag and drop yet. A todo item is to use it for reordering children. I need to get that down before considering other possibilities. The relationship views that I stripped down and refactored I think had that and I removed it till I can examine it closer.

As with the relationship and combined views clicking on a name will navigate to that person. Again a right click on any frame will open a context sensitive action menu with available actions. So options for the active person in the header will differ from the actions if you click on them as a sibling in their family and all that.

No joy doing that manually. But then I don’t use GitHub’s tools. (Did not seean obvious offer to download the individual files. Just view them.) So I just created a file matching the filename, viewed as raw, copied & pasted. No error but the registration thinks there’s something wrong with the .gpr.py file.

image

Then found the zipped Code download. (Surely that button wasn’t dark green before?!?) Expanded that into the %AppData%\gramps\gramps51\plugins folder
Extract to that folder created a subfolder named
profileview-master

same error message. Renamed as “profileview” … same error message

I had no trouble using the zip file download. I used “ProfileView” for the folder name within plugins.

Thanks. That’s the foldername I saw in the README.md and used in the manual attempt. Just tried it again with the ZIPped files … then with Gramps Portable. Still no joy

Did you restart Gramps too?

Yeah. Then used the Plug Manager to uninstall the Person Profile add-on (evidently, it registered even with the error message) to reset any potential for caching in the Registration routine. Checked the Plugins folder. It was gone. Quit Gramps. Restarted Gramps to verify no error, quit Gramps.

Re-extracted from the ZIP to the desktop. (which created a profileview-master folder within a profileview-master folder). Renamed the lower folder to ProfileView and dragged it to the
C:\Users\<~username>\AppData\Roaming\gramps\gramps51\plugins folder
Start Gramps. Error.

I really like this view. Had no trouble on Mac downloading folder and running.

I did get an error when I navigated to a person who did not have a birth-type event.
It worked fine if there was a birth but no death event. Even worked if a baptism event instead of a birth event.

173230: ERROR: person_profile.py: line 758: 'NoneType' object has no attribute 'date'
Traceback (most recent call last):
  File "/Users/gary/Library/Application Support/gramps/gramps51/plugins/ProfileView/person_profile.py", line 753, in change_person
    return self._change_person(obj)
  File "/Users/gary/Library/Application Support/gramps/gramps51/plugins/ProfileView/person_profile.py", line 825, in _change_person
    config=self._config,
  File "/Users/gary/Library/Application Support/gramps/gramps51/plugins/ProfileView/frame_groups.py", line 233, in get_timeline_profiles
    group = TimelineGrampsFrameGroup(dbstate, uistate, person, router, config)
  File "/Users/gary/Library/Application Support/gramps/gramps51/plugins/ProfileView/frame_timeline.py", line 121, in __init__
    groups=groups,
  File "/Users/gary/Library/Application Support/gramps/gramps51/plugins/ProfileView/frame_event.py", line 114, in __init__
    span = Span(birth.date, event.date)
AttributeError: 'NoneType' object has no attribute 'date'

Ah! Thanks for that, I will look into it later on tonight.

I have only tested on Linux as that is all I run, so that is first thought that pops to mind as I don’t know if there are any cross platform concerns. If you start Gramps from command line do you get any error info like Gary did?

Starting from the command line in Windows 10 gives the following error:

2021-06-19 15:31:03.889: WARNING: _manager.py: line 308: Plugin error (from 'person_profile'): No module named 'typing'

and a similar note in the Status line’s “lightbulb” Warning:

WARNING ._manager: Plugin error (from 'person_profile'): No module named 'typing'

am I reading the docs right? Our Windoze Python version doesn’t like the multi-line commenting format???

At first sight this looks good, but want to try it, but will have to be another time :slight_smile:

Doesn’t support type hints. I just pushed a commit that ought to remove them if you want to try again. People with no birth or alternate birth events should be okay now too.

2 Likes

It works! It WORKS!!!
[After the patch was posted to remove Windows incompatible hints]

sweet Mary, mother of… That’s a LOT of configuration options!

First try.

Try using it in dark mode (everthing is wrote in blank):

It’s good with regular white mode:

It seems it doesn’t like my IDs with & inside them:



(entity doesn’t ends with ; you have probably used a & sign with no wish to write an entity - escape & with &amp;)

But I really like it !

oups… I just try moving from one person (with & issue) to another and it don’t move anymore: just the sandglass forever

Hmmm. A few suggestions

  1. The View mode’s Edit menu could use the Tag: New Tag… & Organize Tags… submenu items.
  2. Could you sort the Citations by date?
  3. In the Timeline, could you artificially force an undated Burial event to sort after a Death event?
  4. And in date approximations, calculate End-Of-Life events (Death, Burial, Probate, Will, Cause of Death, Cremation, Retirement) at the end of the approximation & calculate the age based on that too? (e.g., burial in 1968 is considered 31Dec1968 in the timeline ordering rather than 1Jan1968)
  5. in the panel context menus, add the option to clipboard the object
  6. Add Help & Reset to Default buttons to the Configure panel