about summary refs log tree commit diff stats
Commit message (Collapse)AuthorAgeFilesLines
...
* css: resolve units to px before layoutbptato2024-12-168-228/+237
| | | | Lets us skip a couple pointless multiplications/divisions during layout.
* gemini: fix known hosts not being read on *BSDbptato2024-12-161-0/+1
| | | | Only glibc starts from the file's beginning with "a+".
* ua.css: fix checkbox decorationbptato2024-12-151-1/+1
|
* layout: do not allow canpx for scFitContentbptato2024-12-153-2/+8
| | | | | The test case attached is undefined in CSS 2.1, but css-sizing-3 wants us to just ignore the width property (I think).
* layout: also propagate xminwidth from table captionbptato2024-12-151-0/+1
| | | | | | | this is necessary too, now that I think of it (well, table caption sizing is still half-broken, but that's a problem for another day...)
* layout: set table intrinsic min width to specified widthbptato2024-12-153-0/+21
|
* quirk.css: remove unimplemented propertiesbptato2024-12-151-4/+1
|
* Unify assert.js for testsbptato2024-12-153-37/+15
| | | | | judging from the symlink, I probably meant to do this but forgot to finish it
* layout: do not trust specified table cell heightbptato2024-12-153-3/+14
| | | | | If the contents are larger than the specified cell height, then it is simply ignored.
* Fix typobptato2024-12-151-1/+1
|
* chabookmark: fix new item placement, better error handlingbptato2024-12-151-18/+25
| | | | it should put it after the old items, not before them.
* dom, css: fix case-insensitive class/id/attr matchingbptato2024-12-158-28/+74
| | | | Uses an additional lower-case map for O(1) case-insensitive comparisons.
* md2html: add heading class to heading anchorsbptato2024-12-152-6/+9
| | | | makes it easier to hide them
* select: fix height definitionbptato2024-12-151-13/+10
| | | | | now I sort of understand how it works. basically maxh and maxw represent the inner area occupied by the widget at any time.
* chabookmark fixes & improvementsbptato2024-12-159-29/+55
| | | | | | | | * correct action on M-b * add external.bookmark option * move openFileExpand functionality into unquote * add menu items * update docs
* config.toml: move cmd definitionsbptato2024-12-151-228/+228
|
* Add chabookmark scriptbptato2024-12-146-19/+250
| | | | | | | | | | 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
* client: document readFile, writeFile; add getenv, setenvbptato2024-12-142-7/+62
| | | | | | | | Both are quite useful. readFile and writeFile got a small makeover in error handling; in particular, readFile now returns null instead of the empty string when the file is missing and writeFile throws a TypeError on I/O errors.
* css: align h[1-6] behavior with w3mbptato2024-12-144-0/+30
| | | | | | | | | | | Implemented using proprietary selectors -cha-first-node and -cha-last-node, modeled after -moz-first-node and -moz-last-node. I think they are compatible. That does mean this is more limited than w3m's trimming, e.g. it can't really deal with nesting or empty tags. I think this is fine, as it's mainly meant for unstyled documents in the first place (which are unlikely to have e.g. MAIN tags).
* cascade: misc cleanupbptato2024-12-141-6/+3
|
* md2html: fix newline after list before EOFbptato2024-12-143-1/+5
|
* ua.css: underline all text typesbptato2024-12-141-13/+13
| | | | Since text is the fallback, just make it the default.
* url: fix file:/ serializationbptato2024-12-142-1/+2
| | | | file:/// is the standard serialization.
* cookie: allow first-party cookies for subdomains with cookie sharingbptato2024-12-142-43/+56
| | | | | | | | Cookie jar separation is already enough to mitigate tracking issues in this case. (Also, the fact that third-party-cookie controlled this made things even more confusing.) Also, add the previously missing host-only flag.
* term: allow ANSI fgcolor + bgcolorbptato2024-12-131-6/+2
| | | | | | | | Not quite sure why I had assumed that this is broken. At least on XTerm, the previous behavior definitely was, e.g. with a white-ish background and white foreground it would end up correcting the contrast to purple even with black CSS color (thus breaking the "no fgcolor with bgcolor" assumption anyway.)
* container, cookie: simplify extractCookies, cookieJar.addbptato2024-12-132-10/+4
|
* dom: remove cached childNodes, children pointersbptato2024-12-131-34/+37
| | | | | | | Instead, just define the actual value over the getter function on the first use. Also, avoid accidentally creating the attributes NamedNodeMap on adopt.
* lunit: remove redundant codebptato2024-12-132-6/+2
| | | | | | using div instead of / is sort of weird, but it makes it clearer if we're dividing floats or layoutunits (and is already what the code uses).
* dom: queryCommandSupported, HTMLIFrameELement stubbptato2024-12-131-0/+7
|
* cookie: remove JS modulebptato2024-12-132-29/+17
| | | | I no longer need it
* twtstr: fix skipBlanksTillLFbptato2024-12-121-1/+1
|
* pager: fix casingbptato2024-12-121-1/+1
|
* url: remove dead codebptato2024-12-121-5/+0
|
* twtstr: reduce copying in atobbptato2024-12-123-10/+12
|
* mimetypes: use cmpIgnoreCase for JS typesbptato2024-12-122-5/+5
|
* mailcap: misc bugfixes & cleanupbptato2024-12-121-63/+43
| | | | | | | | | | | * fix broken newline skipping logic in consume * remove reconsume char buffer (it's not needed with mmap) * pass on backslash to unquote - this makes backslashes in unquoteCommand work as expected (since it parses the command again) * close ps on write failure * add entries even before parse error - this drops a pointless copy of mailcaps. (we could theoretically just use old behavior without the copy, but this feels more intuitive anyway)
* css: CSSComputedValue -> CSSValuebptato2024-12-126-109/+109
| | | | | "Computed" was redundant; other types of values don't have a common type.
* pager: do not prompt for text typesbptato2024-12-112-1/+10
| | | | we hadn't before, and it's annoying when using cha as a pager
* pager, mailcap: misc fixes, add prompt for global mailcapbptato2024-12-1111-290/+482
| | | | | | | | | | | | | | | | | | | | | | | | 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.
* lcgi: fix error handlingbptato2024-12-111-1/+1
| | | | POSIX does not guarantee that an error is negative.
* twtstr: small cleanupbptato2024-12-111-9/+7
|
* layout: small cleanupbptato2024-12-101-60/+60
|
* render: apply visibility to inline boxesbptato2024-12-103-21/+28
|
* pager: remove unused variablebptato2024-12-101-15/+3
|
* pager: fix nil derefbptato2024-12-101-2/+2
| | | | | | isearch feels quite janky in general, and I think there's still a race lurking here... for now it's ok, but like buffer display, this really belongs in a state machine (not promises)
* Update docsbptato2024-12-103-4/+22
|
* Improve error messagesbptato2024-12-104-15/+15
|
* layout: override table cell width if its min width is greaterbptato2024-12-103-0/+17
| | | | We can do this now that xminwidth is more accurate.
* layout: proper min width clampingbptato2024-12-101-73/+70
| | | | better
* layout: another min width clamping hackbptato2024-12-101-20/+29
| | | | still not quite right, but it's slowly taking shape