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

Allow initializing an [Editabled/ReadOnly]StyledDocument with content #645

Merged
merged 2 commits into from
Nov 17, 2017

Conversation

JordanMartinez
Copy link
Contributor

@JordanMartinez JordanMartinez commented Nov 17, 2017

Resolves #646

No longer adddresses #644

Before this, the initial document must always be empty

Before this, the initial document must always be empty
@JordanMartinez JordanMartinez changed the title Allow initializing an EditableStyledDocument with content Allow initializing an ReadOnlyStyledDocument with content Nov 17, 2017
@JordanMartinez JordanMartinez changed the title Allow initializing an ReadOnlyStyledDocument with content Allow initializing an [Editabled/ReadOnly]StyledDocument with content Nov 17, 2017
@JordanMartinez
Copy link
Contributor Author

By following the idea I listed in #644 by exposing ROSD's main constructor (it takes a List of paragraphs as its argument), it allows a developer to pass in paragraphs that don't all use the same SegmentOps object, which could lead to bugs later on. By adding a builder that handles that more appropriately (and resolves #646), this isn't an issue.

@JordanMartinez JordanMartinez force-pushed the exposeMoreConstructors branch 2 times, most recently from 34686c6 to e243a18 Compare November 17, 2017 06:20
@JordanMartinez JordanMartinez merged commit 22fef6e into FXMisc:master Nov 17, 2017
@JordanMartinez JordanMartinez deleted the exposeMoreConstructors branch November 17, 2017 06:33
@JordanMartinez
Copy link
Contributor Author

I've updated the snapshot version to include this PR.

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.

1 participant