Skip to content

Conversation

@AkshayWarrier
Copy link
Contributor

@AkshayWarrier AkshayWarrier commented Jul 29, 2023

This PR aims to make improvements to the Documentation Viewer.

  • Port the old UI to the new libadwaita 1.4 widgets. The Documentation Viewer now uses a NavigationSplitView for the sidebar.
  • Sidebar now shows not only namespaces but also sections and subsections for each namespace using collapsible TreeExpanders

@AkshayWarrier
Copy link
Contributor Author

This is not ready to be reviewed yet, I might have an idea why it's not working. I want to try something first :)

@AkshayWarrier AkshayWarrier self-assigned this Aug 3, 2023
@AkshayWarrier AkshayWarrier marked this pull request as ready for review August 4, 2023 16:38
@AkshayWarrier
Copy link
Contributor Author

AkshayWarrier commented Aug 4, 2023

Some things to consider

  • There is no section for Function Macros like DevHelp and they are added with the Functions section because both files are named as func.xx.html and I have no way to differ between them
  • We could try synchronizing the item selected in the sidebar and the doc shown by the webview? Sometimes the user may click on links on the doc that redirect them to some other page. (Will have to think how to do this though)

@AkshayWarrier AkshayWarrier changed the title Documentation Viewer: Improved sidebar Documentation Viewer: Improvements Aug 14, 2023
@AkshayWarrier
Copy link
Contributor Author

AkshayWarrier commented Aug 14, 2023

For some reason, I'm unable to change the default selected item in the sidebar when the doc viewer is first opened.

Scrolling in the web view is broken and also switching between sections in the documentation (when the sections are on the same page) potentially because of https://bugs.webkit.org/show_bug.cgi?id=260073

Edit: This issue is not persisting anymore after updating org.gnome.Platform//master (i think)

@AkshayWarrier AkshayWarrier requested a review from sonnyp August 14, 2023 18:22
@sonnyp sonnyp assigned sonnyp and unassigned sonnyp and AkshayWarrier Aug 19, 2023
Copy link
Contributor

@sonnyp sonnyp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great!

I pushed minor changes, make sure to git pull.


image

I think we should remove empty sections like Bitfields and Error Domains in this example.

If you prefer, you can create a follow up ticket.


When navigating back, it should select the relevant sidebar item.

This should probably be a follow up though.

@AkshayWarrier AkshayWarrier requested a review from sonnyp August 20, 2023 05:01
@sonnyp sonnyp changed the title Documentation Viewer: Improvements Manuals: Improve design and use TreeExpander Aug 20, 2023
@sonnyp sonnyp merged commit 408a19a into main Aug 20, 2023
@sonnyp sonnyp deleted the akshaywarrier/docviewersidebar branch August 20, 2023 09:19
@sonnyp sonnyp assigned AkshayWarrier and unassigned sonnyp Aug 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants