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

Consider using multiple paragraphs instead of multiple inlines in a single paragraph #11

Open
augustoproiete opened this issue Aug 7, 2021 · 9 comments
Labels
enhancement New feature or request help wanted Extra attention is needed up-for-grabs
Milestone

Comments

@augustoproiete
Copy link
Member

Currently, each new log entry appends a corresponding Inline object to the last Paragraph in the RichTextBox.

One user reported that writing log entries creating multiple paragraphs seem to have a better performance than creating multiple inlines in a single paragraph once the number of entries is large (the example was ~6000 lines with 4-5 tokens in each entry).

If that is true (needs testing/PoC), then it probably makes sense to switch to using multiple paragraphs by default.

One downside of using multiple paragraphs is that by default the control appends a margin which visually looks like each entry is using two lines instead of one, thus the user would have to remove the default margin of the control:

<Style TargetType="{x:Type Paragraph}">
    <Setter Property="Margin" Value="0"/>
</Style>

I don't think the sink should be making any changes to the visual aspects of the RichTextBox control, thus if we go this route, we should document the margin issue above

@augustoproiete augustoproiete added enhancement New feature or request help wanted Extra attention is needed up-for-grabs labels Aug 7, 2021
@TonyValenti
Copy link

Hi @augustoproiete -
Can I pay you to roll in this enhancement and a few others:

  1. If a URL is logged, please convert it to a clickable HyperLink
  2. Related to the above, add an option to auto-trim the text box. If, after writing, a log entry, the text box has more than X number of paragraphs, remove the first items from the text box until there are less than X.

@augustoproiete
Copy link
Member Author

@TonyValenti Very interesting ideas. Tracking via #15 and #16 to discuss design. They could potentially be done independently of this issue though definitely related

@TonyValenti
Copy link

Any chance you could give me a quote on getting this work done?

@TonyValenti
Copy link

@augustoproiete ?

@TonyValenti
Copy link

We are having performance problems with longer running apps because this is not implemented. Any chance you can make it happen soon?

@augustoproiete
Copy link
Member Author

@TonyValenti I'll see if I can block some time over the next few weeks, but happy to take a PR if you'd like to give it a go

@c0nstexpr
Copy link

c0nstexpr commented Jun 18, 2024

Any update for this?

@TonyValenti
Copy link

I have code that does this and makes the library much more performant but the manager has stopped replying.

@TonyValenti
Copy link

#32

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed up-for-grabs
Development

No branches or pull requests

3 participants