Skip to content

Flushed indentation for wrapped text on bullet point lists#124

Open
MysterieCatDev wants to merge 14 commits into
elly-code:mainfrom
MysterieCatDev:list-wrapped-indentation
Open

Flushed indentation for wrapped text on bullet point lists#124
MysterieCatDev wants to merge 14 commits into
elly-code:mainfrom
MysterieCatDev:list-wrapped-indentation

Conversation

@MysterieCatDev
Copy link
Copy Markdown
Contributor

What this does

This PR:

  • Adds flushed indentation to bullet point items that have overflowing text that wraps.
  • Adds Fedora dependency installation instructions
  • Removes a small print statement that was personally irritated me when testing :D

Fixes #120

Screenshots

image

@teamcons
Copy link
Copy Markdown
Collaborator

teamcons commented May 9, 2026

Hi!
Your screenshot has a very... Broken appearance. Is there a reason for that? I assume meson install?

Could you please open a separate PR against main for the Fedora instructions ? Ill merge immediately

I had in mind an approach but we had no time to try it out. Will try yours beforehand and see how it goes. Thank you for the time spent and efforts <3 will come back to you!

@MysterieCatDev
Copy link
Copy Markdown
Contributor Author

MysterieCatDev commented May 9, 2026

Hi! Your screenshot has a very... Broken appearance. Is there a reason for that? I assume meson install?

I wasn't sure what the issue was but I figured it was just dev-jank. I was just running the program straight from the builddev src folder. In the end I figured it was unrelated to the functionality improvements so it probably wasn't a big deal.

Could you please open a separate PR against main for the Fedora instructions ? Ill merge immediately

👍 in #125

I had in mind an approach but we had no time to try it out. Will try yours beforehand and see how it goes. Thank you for the time spent and efforts <3 will come back to you!

@teamcons
Copy link
Copy Markdown
Collaborator

Daily driving a dev build for a couple days, but this seems to hit the same issue ive met with the proof of concept in #121
As in, different zooms break the clean indentation.

Yours is a bit smarter, initial size always works, but also breaks down faster.

I had in mind to hot-fix the TextTag on zoom change, and introduce a to_indent_spacing() method for each zoom level. However did too much dev things lately so will have to wait a bit

@MysterieCatDev
Copy link
Copy Markdown
Contributor Author

Daily driving a dev build for a couple days, but this seems to hit the same issue ive met with the proof of concept in #121 As in, different zooms break the clean indentation.

Yours is a bit smarter, initial size always works, but also breaks down faster.

I had in mind to hot-fix the TextTag on zoom change, and introduce a to_indent_spacing() method for each zoom level. However did too much dev things lately so will have to wait a bit

Ahh yeah, I didn't even test with the zoom settings. Try this update and let me know what you think, basically just attempting to remeasure any time the zoom level changes.

@teamcons
Copy link
Copy Markdown
Collaborator

Looks pretty good! Running a dev build for a couple days, will check where it breaks or not

@teamcons
Copy link
Copy Markdown
Collaborator

Okay, im back

Theres a couple issues:
-Indentation isnt persistent. It is reset when app starts up
-It breaks quite horribly if user changes list prefix within the same session
-Using as list prefix the current default: " • " (two spaces, one before one after), ive noticed sometimes indenting can break spectacularly (not sure how to reproduce)

it isnt quite there but it is approaching!

@teamcons
Copy link
Copy Markdown
Collaborator

teamcons commented May 15, 2026

This is real good
note: For the last few miles im happy to overtake the PR, if you are tired of this

Mostly trivial stuffs i can see

  • Undo, redo operations break the feature.
  • Still a bit of unaligned indent for zooms below 80%

Id reduce a bit the spacing,
and make '• ' the default... Or add spacing after the bullet

@MysterieCatDev
Copy link
Copy Markdown
Contributor Author

I'll see what I can do, I think they're all easy fixes.

I just have a lot of projects I'm juggling at the moment, and work, so it's a little difficult to get to this in a timely manner but I will definitely get to it for sure. That said, If you want to step in with a commit or two, I won't complain. :)

@teamcons
Copy link
Copy Markdown
Collaborator

Lots of stuff here too. I dont mind....
Theres a Jorts release start of June planned for the seasonal icon, but itll be ready for it by then, whether you or i do the last miles

@MysterieCatDev
Copy link
Copy Markdown
Contributor Author

Oh man that's plenty of time, especially compared to how much we've done in how little time it's taken to do it.

@MysterieCatDev
Copy link
Copy Markdown
Contributor Author

So I skipped breakfast :D I think this should fix those issues. Local testing looked okay but let me know.

Comment thread src/Widgets/TextView.vala
Comment on lines +26 to +28
var old_prefix = _list_item_start;
_list_item_start = value;
migrate_list_prefixes (old_prefix, value);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Suggested change
var old_prefix = _list_item_start;
_list_item_start = value;
migrate_list_prefixes (old_prefix, value);
migrate_list_prefixes (_list_item_start, value);
_list_item_start = value;

Id rather set the sauce to the new sauce after we migrated everything

Comment thread src/Widgets/TextView.vala

private Gtk.EventControllerKey keyboard;
public string list_item_start {get; set;}
private Gtk.TextBuffer? observed_buffer;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

i struggle with the whole observed_buffer thing. It feels very wrong, we end up with twice the amount of text per sticky note in memory (not even counting the gtk cruft), and compare them constantly at every change

i really need to sit down and work on this

@teamcons
Copy link
Copy Markdown
Collaborator

So I skipped breakfast :D I think this should fix those issues. Local testing looked okay but let me know.

kjhbrgkdfgb breakfast first, Jorts isnt worth skipping breakfast. Please take care of yourself.

i feel like we have created a monster

@teamcons
Copy link
Copy Markdown
Collaborator

Added thoughts, but the ability for users to set their own prefix may just not be easily maintainable with ths
i may follow up the PR with a list of choices, that are all one symbol, so the size of prefix would not be variable, and people would choose from a Dropdown.

less weird for users, and probably easier for all this

@MysterieCatDev
Copy link
Copy Markdown
Contributor Author

Added thoughts, but the ability for users to set their own prefix may just not be easily maintainable with ths i may follow up the PR with a list of choices, that are all one symbol, so the size of prefix would not be variable, and people would choose from a Dropdown.

less weird for users, and probably easier for all this

Yeah, people are probably more concerned with getting bulleted lists over the exact format of the bullet itself, so this is probably a good move and would definitely reduce some of the complexity. That said, feel free to branch this branch go nuts.

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.

Bullet lists wrap / don't respect the bullet

2 participants