summaryrefslogtreecommitdiff
path: root/src/ui/documentwidget.c
AgeCommit message (Collapse)Author
2021-10-18DocumentWidget: Unsupported content downloadsJaakko Keränen
Don't try to show a document while a long download is progressing, especially if we don't have any way to present the document format.
2021-10-17FontPack management via "about:fonts"Jaakko Keränen
2021-10-17Media and FontPacks (work in progress)Jaakko Keränen
Saving this as the last point of progress. This direction is too complicated: Media needs to be a lot more sophisticated to allow dynamic and interactive media at the level of FontPacks. (A bit like Player handles audio playback.) This will be reverted. FontPack management will happen using an another method.
2021-10-15Text: Fixed a line wrapping issueJaakko Keränen
When the last safe break position was not in the current attributed run, the calculated wrap advance came out incorrect. This was possible when the first glyph in an attributed run didn't fit.
2021-10-15Preferences: Option to bold visited links, tooJaakko Keränen
Cleaned up serialization of the bool preferences a little.
2021-10-14Preferences: ANSI escape sequences in GemtextJaakko Keränen
It can be argued that using ANSI escapes to style text goes against the intended use of Gemtext. Therefore, all ANSI escapes are now disabled by default in Gemtext.
2021-10-14DocumentWidget: Fixed media type checkingJaakko Keränen
2021-10-13Text attributes that change inside a runJaakko Keränen
These changes concern the situation when the attributes of text (i.e., font, color) are changed via escape sequences. The concept of "base attributes" was added so that the low-level text renderer knows which font/color to set when a "reset" escape sequence is encountered. This depends on what kind of text is being renderer, e.g., preformatted or regular paragraphs. The base attributes were added as variables in Text because it was getting unwieldy to pass all the information via the draw/measure/WrapText functions. GmDocument now has a GmTheme struct that collects the font and color information into a single place.
2021-10-12Experimental Markdown renderingJaakko Keränen
Convert Markdown to Gemtext and use ANSI escape sequences to switch fonts (bold, italic, monospace). The conversion is still a bit buggy...
2021-10-11Merge branch 'dev' into work/v1.8Jaakko Keränen
# Conflicts: # CMakeLists.txt # res/lang/es.bin # res/lang/fr.bin # res/lang/gl.bin # res/lang/ie.bin # res/lang/ru.bin # res/lang/sk.bin # res/lang/sr.bin # res/lang/tok.bin # src/ui/documentwidget.c
2021-10-11DocumentWidget: Fixed text selection regressionsJaakko Keränen
The HarfBuzz and wrapped text changes introduced subtle differences in how text selection works. Fixed a bunch of issues regarding how the individual character selection mode works in edge cases. IssueID #357
2021-10-11Media refactoring; working on FontPack managementJaakko Keränen
Media still needs more work to get rid of redundancies and make lookups faster. FontPacks are manipulated as Media items (not unlike images) so they can be previewed on page, and installed via a click. FontPack management is not trivial as it includes such details as versioning and whether individual packs are enabled or disabled.
2021-10-08Font configuration; Prefs has a string value arrayJaakko Keränen
Added a second version of Iosevka with more line spacing, to be used as the default monospace document font.
2021-10-07DocumentWidget: Line width based on font glyph widthJaakko Keränen
The idea is that the amount of content should be the same per line regardless of the font.
2021-10-06Revised runtime font managementJaakko Keränen
The built-in fonts are loaded via FontPack, and the font table is now constructed dynamically based on available fonts. A full set of variants (style, size) are prepared for each font, but some of the data gets allocated lazily when needed. GmRun needed a larger allocation for fonts, so now all the fields are combined into a single bit field. TODO: Glyph scaling, vertical offsets, and symbol lookup are still not fully working.
2021-09-28DocumentWidget: Showing error page on untrusted certsJaakko Keränen
2021-09-27CommentJaakko Keränen
2021-09-27Minor UI tweaksJaakko Keränen
2021-09-26Minor UI tweaksJaakko Keränen
2021-09-25Merge branch 'work/v1.7' into devJaakko Keränen
2021-09-20Experimenting with independent popup windowsJaakko Keränen
Toe dipping into multiple window support by allowing popup menu widgets to be displayed in independent windows. This is not a 100% replacement for native menus, but it gets pretty close.
2021-09-19Refactoring Window to split off MainWindowJaakko Keränen
MainWindow represents (one of) the main windows of the app, while the basic Window will be a used for popups. Only MainWindow supports split view modes.
2021-09-13Mobile: New selection logic for InputWidgetJaakko Keränen
Touch-based interaction requires a different kind of selection and copy/paste behavior. This isn't done yet; especially multi-line text still needs work.
2021-09-11Mobile: Many UI improvements; Upload UIJaakko Keränen
2021-09-09Mobile: Working on dialogsJaakko Keränen
The new panels maker offers a declarative solution for creating consistent UIs.
2021-09-09Tuned mouse wheel smooth scrollingJaakko Keränen
Removed the two-stage acceleration of mouse wheel scrolling in favor of slightly faster base scrolling speed overall. This makes the behavior more consistent and predictable.
2021-09-07Mobile: Redoing PreferencesJaakko Keränen
Contents of the Preferences split panel view are created based on arrays of MenuItems. This removes the confusing indirection of trying to modify the desktop widget tree to fit mobile.
2021-09-04iOS: Minor fixesJaakko Keränen
The SDL text input rectangle function applies some sort of offset that is inappropriate on iOS.
2021-08-29Merge branch 'dev' into work/v1.7Jaakko Keränen
2021-08-29DocumentWidget: Fixed minor text artifactsJaakko Keränen
Clearing the background of all runs is required because sometimes a run will overlap with another, or is drawn multiple times.
2021-08-20Added WebP decoding using libwebpJaakko Keränen
2021-08-20Merge branch 'dev' into work/v1.7Jaakko Keränen
# Conflicts: # CMakeLists.txt
2021-08-18DocumentWidget: Incorrect message in Page InfoJaakko Keränen
2021-08-15Merge branch 'dev' into work/v1.7Jaakko Keränen
2021-08-10DocumentWidget: Fixed drawing of empty documentJaakko Keränen
An empty document would could the widget to be drawn as a black non-themed rectangle, with a single-pixel horizontal line in the middle. This fixes that by just clearing the widget to the UI background color. The most notable situation where this occurred was immediately after activating split view mode.
2021-08-06Merge branch 'dev' into work/v1.7Jaakko Keränen
2021-08-06GmDocument: Full-width images in narrow layoutJaakko Keränen
2021-08-04DocumentWidget: Slightly wider minimum bordersJaakko Keränen
2021-08-02DocumentWidget: Redirecting between gemini/titan schemesJaakko Keränen
Automatic redirects between `gemini` and `titan` are allowed, because a reasonable response to a Titan request is a redirect to a Gemini URL. Gemini may likewise redirect to a Titan URL to initiate an upload.
2021-08-02DocumentWidget: Redirecting between gemini/titan schemesJaakko Keränen
Automatic redirects between `gemini` and `titan` are allowed, because a reasonable response to a Titan request is a redirect to a Gemini URL. Gemini may likewise redirect to a Titan URL to initiate an upload.
2021-08-01Translations for hardcoded English stringsJaakko Keränen
IssueID #276
2021-07-28Titan: Reloading should re-open the Upload UIJaakko Keränen
2021-07-25UploadWidget: Fixes and improvementsJaakko Keränen
Fixed update after undo. Line wrap long destination URLs. Don't open a new upload dialog if one is already open.
2021-07-23Window: Mouse wheel events vs. split modeJaakko Keränen
Only process mouse wheel events on the root over which the mouse is currently.
2021-07-23InputWidget: Buffer contents not activeJaakko Keränen
2021-07-22Added a setting for Return key behaviorJaakko Keränen
User preference for line break / accept behavior in input fields. Still needs to be added to the Preferences dialog.
2021-07-22DocumentWidget: No line breaks in sensitive input modeJaakko Keränen
2021-07-17Working on Titan uploadsJaakko Keränen
There may be a bug in `TlsRequest` when sending out large amounts of data.
2021-07-17GmDocument: Link scheme flagsJaakko Keränen
A better way to keep track of the scheme used in a link.
2021-07-16DocumentWidget: Shortcut for ignoring expirationJaakko Keränen