about summary refs log tree commit diff stats
path: root/todo
Commit message (Collapse)AuthorAgeFilesLines
* config: unify table arrays and tablesbptato2025-04-111-6/+1
| | | | | | | | | | | | | | | | | | [[siteconf]] now just means [siteconf.0], etc. So you can now override parts of default siteconfs/omnirules, e.g. to change the Google search substitute-url, etc. To celebrate this, I've added some more default search engines: * wk: -> Wikipedia * wd: -> Wiktionary * ms: -> Marginalia Search These can be replaced by setting e.g. omnirule.wk = {}, etc. Also, siteconf = {} can be used to clear pre-defined siteconfs. This is an unfortunate deviation in semantics from TOML, but in practice the way it worked before didn't match the spec either, so at least it is now consistent.
* Update docsbptato2025-04-061-1/+0
|
* layout: correct table-caption width calculationbptato2025-04-031-1/+0
| | | | It's surprisingly tricky.
* render: propagate offset to positioned block child before clip box inheritancebptato2025-02-191-3/+0
| | | | also, fix a typo
* dom, stylednode: move more fields, handle pseudo-element getComputedStylebptato2025-01-181-1/+1
|
* render: overprint existing text when painting backgroundsbptato2025-01-161-2/+0
| | | | | | | | Even if we don't do some z-ordering correctly, it's no excuse to paint boxes incorrectly. It's also extremely annoying when I try to use a menu and text bleeds into the drop-down window.
* lunit: use saturation arithmeticbptato2024-12-231-4/+0
| | | | | | | I'm not a fan, because it hides bugs. But working around the overflow errors is starting to get unwieldy. On 32-bit systems, we try to use compiler intrinsics as Nim does.
* Unify PositionStaticLike, update todobptato2025-01-031-16/+42
| | | | | sticky, ruby, writing-mode: lots of complexity for little gain, and the fallback works just as well (if not better)
* Update todobptato2024-12-261-3/+5
|
* Add historybptato2024-12-171-1/+4
| | | | | It's still missing a "color visited links" feature, but it's better than nothing.
* layout, render: implement overflow propertybptato2024-12-181-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Overflow pretty much requires scrollbars, but those wouldn't work in dump mode, plus of course they would be a pain to implement. So as a simple alternative: * overflow: hidden, clip works as per spec. * overflow: auto, overlay, scroll invert the intrinsic minimum size clamping logic instead of adding a scrollbar. What this concretely means, is that this <pre style="overflow: scroll; height: 1em"> test test test </pre> will, instead of creating a scroll container, just override the specified height. This hack works surprisingly well, because CSS pretty much requires setting height on scroll containers, so authors aren't incentivized to set height on the parent container too (because the contents are already sized appropriately). One issue left is how to deal with overflow: hidden ancestors. For now, I've made it so that it can spill for overflow-x, and always clips on overflow-y, because it's much less likely to bleed into other text horizontally than vertically. But there is definitely room for improvement, e.g. we could track space requested by scrolling children and expand parent boxes based on that.
* layout: propagate intrinsic minimum heightbptato2024-12-171-0/+5
| | | | | | | | | | | | Necessary for flex. Previously we just used the actual height, but that didn't account for boxes that size themselves depending on the available height (mainly just images for now). This also irons out intrinsic min width calculation somewhat, squashing several bugs. I hope it works well. It is a significant change in size calculation, so maybe there are still new bugs lurking.
* Add chabookmark scriptbptato2024-12-141-1/+1
| | | | | | | | | | Finally it's done. It's basically w3mbookmark, but using Markdown instead of HTML and in POSIX shell instead of C. As a bonus, it can also (sort of) import w3mbookmark's output. Well, at least it worked on my bookmark file, but there is a known issue with bracket escaping... if it goes wrong, it's simple enough to edit it manually :P
* pager, mailcap: misc fixes, add prompt for global mailcapbptato2024-12-111-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | In the past, Chawan would read global mailcap (/etc/mailcap, ...) too, but every now and then that would run entries that I didn't even know existed and definitely didn't intend to run. So I changed it to only use ~/.mailcap, but this meant users now had to add mailcap entries for every single mime type. At some point I also changed application/octet-stream to always save to disk, which is usually nice except when a text file is misrecognized as binary. Often times I just want to decide myself what to do. So now there are two layers. First, the global mailcap files (path as per RFC) prompt before executing. Then there is ~/.chawan/auto.mailcap (or ~/.config/chawan/auto.mailcap) which runs entries automatically. If you press shift before selecting an option in the prompt, the corresponding entry gets copied to auto.mailcap. It's also possible to type a new entry on the fly. Overall I think it's quite convenient. One unfortunate side effect is that existing users will have to migrate their entries to auto.mailcap, or redefine external.auto-mailcap to e.g. ~/.mailcap, but this seems acceptable.
* config.toml: respect TMPDIRbptato2024-11-121-1/+0
| | | | | also, fix a bug in the chapath parser so that param expansion actually works
* layout: fix initial flex item width calculationbptato2024-11-081-2/+1
| | | | | | | | | | | | | | | Before, the initial layout of a flex item would have inherited the parent's sizing constraint. This almost worked, except when a descendant of a flex item with an unspecified width would resolve its percentage against this incorrectly inherited width - per standard, this must resolve to auto. Also, the shrink case was wrong, because it did not scale the unit to the respective widths; the standard mandates this as well. Hopefully I got it right this time. Finally, this fixes positioned inline container blocks not being set as the absolute container.
* protocol: sandbox more network processes + fix some gemini bugsbptato2024-11-021-2/+0
|
* layout: fix float positioning in inline contextsbptato2024-10-151-4/+0
| | | | | | also fixes a bug in the previous commit where whitespacenum would be reset on absolute positioning + missing absolute margin handling without top/left/etc.
* layout: correct `position: absolute' (FINALLY)bptato2024-10-151-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes a) resolution of `position: absolute' percentage sizes with an indefinite containing block size (wait what?), and b) positioning of `position: absolute' inner block boxes inside inline boxes. a) is possible because `position: absolute' does not affect its parent's layout. I would love to have a long talk with whoever thought that specifying it like this is a good idea. You know, just because you can... anyways, shockingly enough, this was still the more straightforward part. b) forced me to change the box tree to allow blocks inside inlines, which is ugly, but no big deal. Two questions then remained: 1. *where* to put such boxes, and 2. *how large* these boxes should be; this is hardly obvious since an inline box does not have an unambiguous width or height. Of course the CSS standard, never too eager to fulfill my basic expectations, says nothing about this (other than "it's not defined"). So I first tried to reverse engineer what Gecko does, and after hours of pain and suffering I realized... that it's broken LOL https://bugzilla.mozilla.org/show_bug.cgi?id=489100 Therefore I ended up (partially) copying Blink behavior, which, while equally nonsensical as Gecko (and of course divergent), at least does not change after a partial layout. Thank you LayoutNG for saving my sanity. As for the practical benefits: this fixes the bug where Invidious [video] tags wouldn't show up. Hey, it's something! Still left to-do: `position: absolute' for `display: inline' boxes.
* gmifetch: rewrite in Nimbptato2024-10-121-2/+0
| | | | | | | | | | This finally makes it possible to use socks5 for Gemini. Also slightly refactored the config, to make it easier to pass on the config dir. By the way, the known_hosts file is now stored in the config dir too. The adapter will try to move it to there from the old location.
* Update docsbptato2024-10-101-1/+1
|
* container: don't show hover type on ubptato2024-09-271-1/+0
| | | | it's a waste of space, and doesn't work well with showFullAlert
* pager: make image ordering deterministicbptato2024-09-251-1/+1
| | | | ensure that images are shown in the order buffer sent them
* sixel: support transparencybptato2024-09-241-1/+1
| | | | | | | | | | | | | | | | | | Sixel can only represent transparency for fully transparent (alpha = 0) and fully opaque (alpha = 255) pixels, i.e. we would have to do blending ourselves to do this "properly". But what do you even blend? Background color? Images? Clearly you can't do text... So instead of going down the blending route, we now just approximate the 8-bit channel with Sixel's 1-bit channel and then patch it up with dither. It does look a bit weird, but it's not *that* bad, especially compared to the previous strategy of "blend with some color which hopefully happens to be the background color" (it rarely was). Note that this requires us to handle transparent images specially in term. That is, for opaque ones, we can leave out the "clear cells affected by image" part, but for transparent ones, we must clear the entire image every time.
* pager: improve hover text handlingbptato2024-09-221-14/+13
| | | | | | | | | | | * align status truncating behavior with w3m (not exactly, clipping is still different, but this should be fine for now) * add "su" for "show last alert" - w3m's solution here is to scroll one char at a time with "u", but that's extremely annoying to use. We already have a line editor that can navigate lines, so reuse that instead. * fix peekCursor showing empty text * update todo
* md2html: support blockquotebptato2024-08-301-1/+0
| | | | + update todo, readme
* term: fix crash on identical stacked imagesbptato2024-08-271-2/+2
| | | | | | | in fact, we consider these to be the same image, and arguably that's a bug in and of itself. but at least we don't crash anymore. (also, update todo)
* cssvalues, sheet: fix some more case sensitivity bugsbptato2024-08-021-1/+0
|
* client, sandbox: fix termux buildbptato2024-07-241-0/+1
| | | | | Still not perfect, because it crashes on missing /tmp dir so you have to manually set it...
* dom: fix race condition in image loadingbptato2024-07-211-2/+0
| | | | | | We were not setting the invalid flag on bitmap load, so any incremental reshape could interfere with displaying images that got loaded after the reshape.
* config: support smart casebptato2024-07-161-1/+0
| | | | and enable it by default.
* term: query default ansi colors, etc.bptato2024-07-021-1/+0
| | | | | * query default ANSI colors with OSC 4 * disable queries overridden by config
* config: add various missing optionsbptato2024-06-291-1/+0
| | | | | | | Mainly things you could already set with [[siteconf]] but not normally. Also, a `styling' option to disable author styles. Also, `images' is now documented as an "experimental" option, since it's halfway usable now.
* pager: refactor drawing codebptato2024-06-221-1/+0
| | | | | | | * merge select into container * avoid unnecessary redraws in draw() for parts of the screen that haven't been updated * various image redraw fixes
* term, pager: improve image displaybptato2024-06-211-1/+0
| | | | | | * basic repaint algorithm for sixel (instead of brute force "clear the whole screen") * do not re-send kitty images already on the screen
* img, loader: separate out png codec into cgi, misc improvementsbptato2024-06-201-7/+2
| | | | | | | | | | | | | | | * multi-processed and sandboxed PNG decoding & encoding (through local CGI) * improved request body passing (including support for output id as response body) * simplified & faster blob()/text() - now every request starts suspended, and OngoingData.buf has been replaced with loader's buffering capability * image caching: we no longer pull bitmaps from the container after every single getLines call Next steps: replace our bespoke PNG decoder with something more usable, add other decoders, and make them stream.
* layout: resize over-constrained table columnsbptato2024-05-081-3/+0
| | | | | | | | | If the total specified column width is larger than the table's allowed width, we now resize them proportionally to the specified width. This is quite important because many tables set the width to e.g. 50% for "give me half of the table", instead of its true meaning "give me half of the page".
* css, dom: simplify ident parsing, canvas fixesbptato2024-05-011-0/+1
| | | | | | | | * add CSSStyleDeclaration setter * move ident maps directly into enums * more complete CSSComputedValue stringifier * turn canvas into a pseudo-image in cascade * set canvas to inline-block
* term: add sixel encoderbptato2024-04-251-6/+10
|
* Initial image supportbptato2024-04-251-1/+5
| | | | | | | | | | | | | | | | | * png: add missing filters, various decoder fixes * term: fix kitty response interpretation, add support for kitty image detection * buffer, pager: initial image display support Emphasis on "initial"; it only "works" with kitty output and PNG input. Also, it's excruciatingly slow, and repaints images way too often. Left undocumented intentionally it for now, until it actually becomes useful. In the meantime, adventurous users can find out themselves why: [[siteconf]] url = "https://.*" images = true
* test: add js & layout testsbptato2024-04-211-1/+0
| | | | (Sadly some layout tests still fail.)
* js: remove automatic function -> closure conversionbptato2024-04-151-2/+0
| | | | | | | | | | | | | | | It's a bad idea for several reasons: * it's inefficient; must allocate an environment for a closure in Nim, even though we already have one in JS * writing macros for automatically creating functions with variadic arguments is suprisingly difficult (see the entire `js/javascript' module) * it never really worked properly, because we never freed the associated function pointer. We hardly used it anyway, so the easiest fix is to get rid of it completely.
* Update todobptato2024-04-151-18/+17
|
* layout: slightly hacky flex-basis implementationbptato2024-04-091-2/+2
| | | | | | | | it's better than nothing. I suppose. (Two-value flex syntax is encouraged even by the standard, so it gets used a lot, and that sets 0, not flex-basis: auto, so not having flex-basis breaks too many things.)
* Initial flexbox supportbptato2024-04-051-1/+5
| | | | | | | | | Still far from being fully standards-compliant, or even complete, but it seems to work slightly less horribly than having no flexbox support at all on sites that do use it. (Also includes various refactorings in layout to make it possible at all to add flexbox.)
* man: rewrite in Nimbptato2024-03-131-6/+2
| | | | | | | | | | | | Depending on Perl just for this is silly. Now we use libregexp for filtering basically the same things as w3mman2html did. This required another patch to QuickJS to avoid pulling in the entire JS engine, but in return, we can now run regexes without a dummy JS context global variable. Also, man.nim now tries to find a man command on the system even if it's not in /usr/bin/man.
* Update todobptato2024-03-041-10/+2
|
* layout: improve/simplify line box error correctionbptato2024-02-281-3/+0
| | | | | | | | | | | | The previous retrofitting of the old renderdocument error correction usually worked, but it still had a horrible flaw in that it assumed that all line boxes are of equal height. So if error was lower for some line than another, it would move *all* lines by a somewhat lower error, and that resulted in overlapping lines. Now we do something much simpler: in flushLine, round each line's height downwards before moving on to the next line. This gets rid of any blanks inbetween lines, and also works much better with cleared floats.
* Update todobptato2024-02-251-4/+0
|
* Update todobptato2024-02-241-1/+4
|