|
|
#46 |
|
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,044
Karma: 3761621
Join Date: Jan 2017
Location: Poland
Device: Various
|
For Windows:
1. delete .qmake.stash 2. in file "SelectCharacter.cpp" in line 111 set path to file "characters.txt". Notice: use double backslashes, eg. QString custom_path = "W:\\Develop\\special_char\\characters.txt"; 3. run console (x64 Native Tools Command Prompt for VS) 4. run qmake (will create new .qmake.stash file) 5. run nmake and wait (remember: NMAKE) 6. in subfolder "release" should be "flowlayout.exe" file 7. run this exe file It works, and overall it's OK. This is exactly the effect I was going for – wrapping the characters to fit the width of the window while keeping the groups fixed. I'd probably condense the spacing between the groups a bit, but that's just an aesthetic detail. Last edited by BeckyEbook; Yesterday at 02:48 PM. |
|
|
|
|
|
#47 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,036
Karma: 7518950
Join Date: Nov 2009
Device: many
|
Yes the spacing between groups by default is 0 since the linebreak is really an invisible QWidget and without layout spacing/margins there is no gap at all.
So I hardcoded an additional height of 15 in the dolayout routine in FlowLayout.cpp. Just look for the "if" that isLineBreak and tweak what gets added to y height. The problem with a flowlayout is that two back to back linebreaks adds no intergroup spacing at all without that hard coded addition. I thought the make distclean removed the qmake stash. And yes, fix the path to characters.txt in SelectCharacter.cpp not windows.cpp. My bad! Thanks for getting it working on Windows. Please make what tweaks you want and then I will start the conversion to xml. Thanks Kevin Last edited by KevinH; Yesterday at 03:06 PM. |
|
|
|
|
|
#48 |
|
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,044
Karma: 3761621
Join Date: Jan 2017
Location: Poland
Device: Various
|
I think it's enough to remove the extra "+15" from the height, since the groups already clearly separate the blocks. I've been experimenting with making the group names bold, and I think that's worth considering as well.
Code:
y = y + lineHeight + verticalSpacing(); Code:
QLabel* lbl = new QLabel(insert_text);
QFont labelFont = lbl->font();
labelFont.setBold(true);
lbl->setFont(labelFont);
|
|
|
|
|
|
#49 |
|
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,044
Karma: 3761621
Join Date: Jan 2017
Location: Poland
Device: Various
|
Maybe we could also include the color in the group name? I have to admit that in my mind, this window looked very similar.
|
|
|
|
|
|
#50 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,036
Karma: 7518950
Join Date: Nov 2009
Device: many
|
Without that 15 added in there is no spacing at all between the groups on MacOS, so we will need to do something platform specific here. Literally, the top of the heading touches the bottom of the preceding line text.
Let's worry about heading colours at some later point. Hard coding colours to work in all platforms under both dark and light is hard especially on Linux. Those types of tweaks can come later. Functionally, is this proof of concept working enough to go ahead and convert it to xml? Last edited by KevinH; Yesterday at 06:26 PM. |
|
|
|
|
|
#51 |
|
Bibliophagist
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 54,471
Karma: 182218685
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
|
Other than the joy of figuring out that I misspelled QT_PLUGIN_PATH (you don't spell plugin with two g's?), it looks good here. I added my personal selection as another group and continued looking good.
|
|
|
|
|
|
#52 |
|
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,044
Karma: 3761621
Join Date: Jan 2017
Location: Poland
Device: Various
|
Yes, OK for me.
|
|
|
|
![]() |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| PageEdit 2.1.0 - Insert Special Character not working | BetterRed | Sigil | 0 | 05-17-2024 10:01 PM |
| Add title="" to h* based on existing TOC -- suggestion for new feature (or plugin?) | Mister L | Sigil | 82 | 09-11-2020 09:09 AM |
| "insert special character" in editor | rjwse@aol.com | Editor | 5 | 08-27-2019 08:31 PM |
| Insert special character: some niggles | Phssthpok | Editor | 2 | 11-19-2016 12:55 PM |
| Feature Request: configurable space setting for "Insert blank line" in "Look & Feel" | therealjoeblow | Calibre | 15 | 07-25-2011 03:14 PM |