[Suggestion][Feature request] Automatic hyphenation

sb
sbradabang
Posts: 31
Joined: Thu Aug 01, 2019 2:31 pm
Platform: Windows

Fri Jun 26, 2020 9:21 am Post

I think this request belongs here, while version 3 for Windows is still in beta.
It would be really good if you could add an automatic hyphenation feature that works in the editor AND in compiling. Hunspell provides hyphenators for almost every language. I'm asking this because an Italian text justified but not hyphenated may get very ugly when too many long words go to a new line without being truncated with a hyphen, leaving the previous line with big spaces between words. So far, I have to compile a project into an .odt, open it with LibreOffice and enable hyphenation.
(If this is too much a grind, forget about it.)

As
Astaff
Posts: 242
Joined: Mon Jun 24, 2019 10:11 pm
Platform: Mac, Win + iOS

Fri Jun 26, 2020 9:38 am Post

I think this request belongs here, while version 3 for Windows is still in beta.


It belongs on the Wish List forum.

On the Beta download page they say.

A Note on Suggestions
To help resolve remaining bugs, we'd appreciate keeping the beta forum posts dedicated to bug reports or questions on working with the beta. Suggestions for the interface or functionality should instead be posted in Scrivener's general wishlist forum, since most of these affect the design for both Windows and macOS. Thank you!

User avatar
devinganger
Posts: 2027
Joined: Sat Nov 06, 2010 1:55 pm
Platform: Mac, Win + iOS
Location: Monroe, WA 98272 (CN97au)
Contact:

Sat Jun 27, 2020 3:22 am Post

I would argue that a good case would be made for including it here, as this is a specific feature offered by the spelling engine used exclusively within the Windows beta (the Mac and iOS versions don't use Hunspell...) This is one of these rare edge cases where yes, it's an extension of functionality, but it's related to functionality already present in the beta and only in the Windows version.
--
Devin L. Ganger, WA7DLG
Not a L&L employee; opinions are those of my cat
Life has a way of moving you past wants and hopes

Do
Dorothea
Posts: 120
Joined: Mon Jan 29, 2018 4:37 pm
Platform: Windows

Wed Jul 01, 2020 2:41 pm Post

I'd like that very much,too . writing in German,which has even longer words than the Italians have.
But a long while ago, they told us that hyphnation is an internal Mac feature and they rely on that . Windows instead doesn't have it as a built-in and therefore it would need a lot of additional work to put it into the Windows version of Scrivener.
So probably there is no hope any time soon.

I, too, compile to odt and finish the files for printing in LibreOffice. But as Scrivener is no DTP program, I think, at the end we'll always need another progam for good-looking paper books.

sb
sbradabang
Posts: 31
Joined: Thu Aug 01, 2019 2:31 pm
Platform: Windows

Thu Jul 02, 2020 8:33 am Post

Dorothea wrote:I'd like that very much,too . writing in German,which has even longer words than the Italians have.
But a long while ago, they told us that hyphnation is an internal Mac feature and they rely on that . Windows instead doesn't have it as a built-in and therefore it would need a lot of additional work to put it into the Windows version of Scrivener.
So probably there is no hope any time soon.

I, too, compile to odt and finish the files for printing in LibreOffice. But as Scrivener is no DTP program, I think, at the end we'll always need another progam for good-looking paper books.


It was, as you said, long time ago. Now they rely upon Hunspell for dictionaries and spelling check in Windows beta, so I think they could add this little thing too. However, I don't know how much an annoyance it may be for developers. This thread is just expressing a hope.
This feature in compiling may be useful if I want to compile directly to a PDF; usually I compile to LibreOffice as well.

User avatar
devinganger
Posts: 2027
Joined: Sat Nov 06, 2010 1:55 pm
Platform: Mac, Win + iOS
Location: Monroe, WA 98272 (CN97au)
Contact:

Thu Jul 02, 2020 8:59 am Post

sbradabang wrote:Now they rely upon Hunspell for dictionaries and spelling check in Windows beta, so I think they could add this little thing too.


Sadly, that probably means it's *harder* to add. It might be best to see if that functionality is being added to Hunspell and/or get them to add it (or the appropriate hooks for it) so that Scrivener can then consume it.
--
Devin L. Ganger, WA7DLG
Not a L&L employee; opinions are those of my cat
Life has a way of moving you past wants and hopes

User avatar
tiho_d
Posts: 1200
Joined: Tue Sep 13, 2011 1:14 pm
Platform: Linux + Windows

Thu Jul 02, 2020 9:28 am Post

Hunspell is a spell checker in its core, and not a hyphenation library. Some packages do extend Hunspell with hyphenation dictionaries, but we have not found something stable and working with a good set of dictionaries in C or C++.

If someone has a reference to a good Hunspell based hyphenation library in C/C++, please let us know.

User avatar
devinganger
Posts: 2027
Joined: Sat Nov 06, 2010 1:55 pm
Platform: Mac, Win + iOS
Location: Monroe, WA 98272 (CN97au)
Contact:

Thu Jul 02, 2020 9:04 pm Post

tiho_d wrote:If someone has a reference to a good Hunspell based hyphenation library in C/C++, please let us know.


Define "good." :)
--
Devin L. Ganger, WA7DLG
Not a L&L employee; opinions are those of my cat
Life has a way of moving you past wants and hopes

User avatar
tiho_d
Posts: 1200
Joined: Tue Sep 13, 2011 1:14 pm
Platform: Linux + Windows

Thu Jul 02, 2020 10:45 pm Post

Library which is already well tested and used in multiple applications with real users and having a good set of hyphenation dictionaries for the most common languages. As I already wrote, must be in C/C++.

User avatar
devinganger
Posts: 2027
Joined: Sat Nov 06, 2010 1:55 pm
Platform: Mac, Win + iOS
Location: Monroe, WA 98272 (CN97au)
Contact:

Thu Jul 02, 2020 11:05 pm Post

I'll do some asking around.
--
Devin L. Ganger, WA7DLG
Not a L&L employee; opinions are those of my cat
Life has a way of moving you past wants and hopes

rw
rwfranz
Posts: 925
Joined: Thu May 28, 2015 9:41 pm
Platform: Windows

Fri Jul 03, 2020 5:41 am Post

Hunspell? Used by LibreOffice for spelling, hyphenation, and some other stuff. Adobe InDesign CS6 also uses Hunspell hyphenation and spelling. Google Chrome; Mozilla Firefox; Adobe Illustrator; QuarkXpress; some others.

Hunspell's official repository(ies), I think: https://github.com/hunspell/hyphen/tree/master

Uses TeX hyphenation patterns (for more info, see https://tug.org/tex-hyphen/).

As Hunspell is already used by Scrivener, you already know some of its quirks.
Just another user.