I would always encourage an author to release something open-source, but it’s ultimately their decision and even the slightest perception of hostility towards them can discourage open-sourcing and even future engagement with the community as a whole.
Personally I’m grateful when anyone shares anything with us, even closed source, because it can, at the very least serve as inspiration for what is possible to create in your own code.
To @Sveinn_Runar_Sigurdsson I’d like to express thanks for what you’ve shared so far and your willingness to accept feature and bug requests. Many of us would indeed love to have an open-source version of the control, if and when you’re comfortable with releasing that, but it’s your decision entirely.
Many community users will flat-out refuse to use something closed-source, I’m sure you can understand that, and you can also benefit from having extra eyes to look it over and identify/fix issues you may be unaware of, so there is definitely a lot to gain for everyone. But again, it’s your decision and seeing as how you mentioned “we” instead of “I,” perhaps the decision may actually be your team’s and not yours personally. So we have to acknowledge that there may be more involved in clearing that than is immediately obvious. But truly, thank you for contributing.
It’s eventually up to me, but one of the main reasons for the encrypted version at this point is that it needs refactoring / documentation etc prior to being opened up, but as a supporter and user of Xojo, an extensive library of available code examples / controls etc etc is fundamental for the platform to thrive , going forward. I for one did not enjoy the development of this control one bit! I wished i could have accessed something ready made.
Furthermore, a flexible rich text editor… is greatly needed and working together on a solution going forward would be great.
Very nice and thanks for sharing! It looks like you used the Open Source Editor Quill as a basis inside a HTML-Control. Neat idea. But why not mentioning it?
I do! Check the github repository. However, it is highly modified with the delta functionality of quill completely stripped out, with tons of features added, including key bindings, custom events and debugging tools… but most importantly, the defined font styling is synced with the content being pasted by the user into the browser. That is done with our own parser and tackles the biggest problem of quill… which was exactly how it handles pasting of data.
But again, Quill is mentioned (first paragraph in the readme.md file).
I’m not trying to be flippant here, but as a former business owner, I’d want some sort of assurance that the software we’re integrating into our product isn’t going to be suddenly unusable because we weren’t cautious enough.
Hi hi, the question is perfectly valid… and the answer was given because I needed that answer as well, when I was working on this…
… that’s why, the major change to the underlying component we based this on (quill 2.0+) was to remove the Delta format completely and go with HTML.
By using HTML your data is in a format that you can plug and play with any of MANY solutions out there.
For example, our mobile app is NOT written in Xojo (It’s written in Dart / Flutter) and it does NOT use RTEdit to view the documents that our desktop users generate.
However, since the format of the document is html (stored in a jsonb field in a Supabase) we could choose from many widgets in flutter to display / edit the content seamlessly.
So…the answer is… the control does not spit out a custom formatted content… it’s HTML and you could drop whatever editor into the future and plug in a new one, with a breeze.
New property EnableRightClick (Boolean)
The EnableRightClick property allows you to enable or disable right-click functionality. By default, right-click may be disabled to prevent users from accessing browser context menus.
This property dynamically modifies the contextmenu behavior via JavaScript execution. The MouseclickRight event is not raised when turned off. Can be changed in runtime.
Bug fix
Fixed an issue in Quill where the bubble toolbar type would not be fully visible when triggered near the top-most or bottom-most lines of the editor. The issue specifically occurred when the toolbar was activated near the top edge or bottom edge of the control, causing parts of the toolbar to be cut off or hidden off-screen.
I would be interested in this once it is available as open source. I use Quill, embedded in a DesktopHTMLViewer, to provide an editor for users of my app to create emails, where the body can be retrieved as HTML. I’ve based that on Quill 1.3.7. To me, it’s 12k lines of largely incomprehensible javascript, but I’ve managed to modify it slightly to integrate with my app. Thus, if someone has taken a more recent version and made it more flexible and done a better job of integrating it with Xojo, that would be very useful to look at and see what extra it offers over my somewhat clumsy integration.
Can it move text around using drag/drop, for instance?
Why so rude?
Greg’s concerns are valid from a business perspective.
And even if that weren’t the case, it would be perfectly fine to want to know why a project is advertised as an open source project on GitHub and here, but then the code is partially encrypted.
It is possible, for example, that the author is unsure because the code may seem unprofessional or chaotic. In this case, for example, you could have offered help and reassured the author that there is no reason to be ashamed because we all started small or were only able to grow with the help of the community.
Where is this discussion going?.. Nowhere do I mention that it’s open source, i shared it as soon as I saw a fellow Xojo forum member looking for a text styling solution. It’s for free to whomever finds it useful for whatever reasons, whether inspiration / showcase / or simply by using it.
As for the discussion… Hopefully I won’t get hit by a bus, I am not “ashamed”, “unsure”, “small” etc etc. You can see by the functionality / exposed interface / or the screenshots alone… that I’m not at a “hello world” level.
I wish you all a peaceful day, in an otherwise turbulent and chaotic world.
I have one more thing to say and then I’ll leave this alone.
@Sveinn_Runar_Sigurdsson - please attach a license in your repo. Personally I don’t care what type as I won’t be using it, but a license file stating what your intentions are at this point in time will be crucial for anyone that wants to include your component in their own projects… especially if they are open source and published on GitHub or a commercial product that will be sold to other users.
Thank you all for the positive feedback and to everyone using the control. I’m glad to be of assistance.
I’ve just updated the control to v0.9.5! This new release introduces a new property:
AllowTextDragDrop
Enabled by default (True), this property allows users to drag styled text from any source into the control, as well as move text around within the control itself. I’m dedicating this one to @TimStreater.
Duplicate support:
While dragging text within the control, holding Ctrl (Windows) or Option (Mac) creates a duplicate of the selected text instead of moving it.