1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-06-20 00:15:31 +00:00
Commit Graph

5209 Commits

Author SHA1 Message Date
Witold Filipczyk
010deec2dc [ecmascript] free_document 2024-02-02 19:44:18 +01:00
Witold Filipczyk
3c5a61b524 [ecmascript] parse document after document.write in onload 2024-02-02 19:33:20 +01:00
Witold Filipczyk
4ee7b050a4 [spidermonkey] localstorage -> localStorage 2024-02-02 19:13:00 +01:00
Witold Filipczyk
9516ca43ff [ecmascript] Always reparse document 2024-01-31 11:32:53 +01:00
Witold Filipczyk
e7562a3120 [spdermonkey] xhr -> XMLHttpRequest 2024-01-31 11:12:32 +01:00
Witold Filipczyk
404e93c773 [spidermonkey] unref dom_node once in finalizer 2024-01-30 20:29:08 +01:00
Witold Filipczyk
379a8edbc9 [quickjs] style.cssText 2024-01-30 17:49:16 +01:00
Witold Filipczyk
64b0898b8c [mujs] style.cssText 2024-01-30 17:36:03 +01:00
Witold Filipczyk
8c58bdfb99 [spidermonkey] style.cssText
For getter just copy style attribute.
For setter more complicated.
2024-01-29 18:57:13 +01:00
Witold Filipczyk
4b7756f74c [spidermonkey] Code special for shellinabox
pre#cursor is width of one cell.
pre#console full width
2024-01-28 18:01:32 +01:00
Witold Filipczyk
2da397a44e [quickjs] offsetWidth and offsetHeight call clientWidth and clientHeight
For <body>, <html> full height.
For <body>, <html> and <div> full width.
2024-01-28 16:47:52 +01:00
Witold Filipczyk
5841cd5c94 [mujs] for <body>, <html> or <div> clientWidth returns full width of window 2024-01-28 16:38:20 +01:00
Witold Filipczyk
84c0b4886b [spidermonkey] full width also for DIV element 2024-01-28 16:29:57 +01:00
Witold Filipczyk
4a94b6150e [spidermonkey] clientHeight and offsetHeight the same function
For <body> and <html> return height or width of screen.
2024-01-28 16:22:15 +01:00
Witold Filipczyk
330bfb7d29 [quickjs] window.innerWidth and innerHeight 2024-01-28 15:24:47 +01:00
Witold Filipczyk
3456d27b22 [mujs] window.innerHeight and innerWidth 2024-01-28 15:20:10 +01:00
Witold Filipczyk
c0a3bce766 [spidermonkey] window.{innerHeight,innerWidth} 2024-01-28 15:14:48 +01:00
Witold Filipczyk
7b3c450293 [quickjs] style.{height,left,top} 2024-01-28 14:27:55 +01:00
Witold Filipczyk
e66f142b7a [mujs] style.{height,left,top} 2024-01-28 14:22:07 +01:00
Witold Filipczyk
0c571b7a3c [spidermonkey] style.top 2024-01-27 21:00:39 +01:00
Witold Filipczyk
3c7b41894e [spidermonkey] style.left 2024-01-27 20:57:16 +01:00
Witold Filipczyk
2c8ffe31f9 [spidermonkey] style.height 2024-01-27 20:53:19 +01:00
Witold Filipczyk
73e507737a [spidermonkey] Return width or height of a single cell for not found elements
For clientHeight and similar.
2024-01-27 20:25:56 +01:00
Witold Filipczyk
1742e87854 [quickjs] offsetHeight and offsetWidth 2024-01-27 16:04:08 +01:00
Witold Filipczyk
8b35062e10 [mujs] offsetWidth and offsetHeight 2024-01-27 15:59:49 +01:00
Witold Filipczyk
8b3ece5b82 [spidermonkey] element.offsetHeight and element.offsetWidth
The same code as clientHeight and clientWidth accordingly.
2024-01-27 15:54:52 +01:00
Witold Filipczyk
224c198781 [quickjs] element.offsetTop 2024-01-27 15:31:39 +01:00
Witold Filipczyk
7c72d49f0c [mujs] element.offsetTop 2024-01-27 15:26:09 +01:00
Witold Filipczyk
317737fa34 [spidermonkey] element.offsetTop 2024-01-27 15:23:09 +01:00
Witold Filipczyk
7bccb89efb [spidermonkey] element.offsetLeft 2024-01-27 15:19:24 +01:00
Witold Filipczyk
8d597b1148 [quickjs] element.offsetLeft 2024-01-27 15:11:38 +01:00
Witold Filipczyk
21187f88c8 [mujs] element.offsetLeft 2024-01-27 15:04:30 +01:00
Witold Filipczyk
8ec6ca70fe [spidermonkey] element.offsetParent (parentNode) 2024-01-27 14:49:54 +01:00
Witold Filipczyk
b61c51ed43 [quickjs] element.offsetParent 2024-01-27 14:45:23 +01:00
Witold Filipczyk
62d21a222e [mujs] element.offsetParent
For now the same as parentNode.
2024-01-27 14:41:54 +01:00
Witold Filipczyk
8238393479 [spidermonkey] element.clientWidth 2024-01-27 14:20:29 +01:00
Witold Filipczyk
bc37d44d52 [quickjs] element.clientWidth 2024-01-27 14:16:48 +01:00
Witold Filipczyk
82dae118f0 [mujs] element.clientWidth 2024-01-27 14:16:34 +01:00
Witold Filipczyk
d8007fafaf [spidermonkey] element.clientHeight 2024-01-27 14:09:24 +01:00
Witold Filipczyk
2800597913 [quickjs] element.clientHeight 2024-01-27 14:02:13 +01:00
Witold Filipczyk
e4b4586780 [mujs] element.clientHeight 2024-01-27 13:54:07 +01:00
Witold Filipczyk
84660b694d [node] get_element -> get_element_rect 2024-01-27 13:53:24 +01:00
Witold Filipczyk
06ffcc8085 [spidermonkey] cell_width and cell_height in screen 2024-01-27 12:34:03 +01:00
Witold Filipczyk
89955cc13a [quickjs] cell_width and cell_height 2024-01-27 12:14:01 +01:00
Witold Filipczyk
bc13ff2e1a [mujs] cell_height and cell_width in screen instead of hardcoded 16 and 8. 2024-01-27 12:08:23 +01:00
Witold Filipczyk
129683d70f [spidermonkey] element.clientLeft and element.clientTop 2024-01-26 21:31:13 +01:00
Witold Filipczyk
a72db310b4 [quickjs] element.clientLeft and element.clientTop 2024-01-26 21:24:13 +01:00
Witold Filipczyk
81c692e6b8 [mujs] element.clientLeft and element.clientTop
They always return 0.
2024-01-26 21:17:30 +01:00
Witold Filipczyk
9e743f0e80 [renderer] Reorder instructions 2024-01-26 19:02:26 +01:00
Witold Filipczyk
9e3d874577 [document] Added function scan document
This function must calculate dimensions of nodes in document.
Every node has a rectangle. x0,y0 is the left up corner, x1,y1 - the right bottom.
In theory every child of given node is contained in this rectangle.
2024-01-26 18:43:33 +01:00
Witold Filipczyk
5c8b62247a [screen] Test commit. Added element_offset to struct screen_char 2024-01-21 17:02:09 +01:00
Witold Filipczyk
937f6b415e [ecmascript] Changed declarations of ecmascript_timeout
Also free functions in quickjs version.
2024-01-20 15:56:23 +01:00
Witold Filipczyk
d34ae1371d [ecmascript] clearInterval and setInterval
Changed return type of ecmascript_set_timeout.
Now it is pointer to struct ecmascript_timeout.
2024-01-19 22:10:02 +01:00
Witold Filipczyk
e77ff5aa8b [quickjs] window.getComputedStyle 2024-01-19 17:17:11 +01:00
Witold Filipczyk
dd87474f06 [mujs] window.getComputedStyle 2024-01-18 20:53:17 +01:00
Witold Filipczyk
797124fc2a [spidermonkey] window.getComputedStyle
It is fake, it returns "0" for "marginTop", "marginLeft" and "marginRight".
2024-01-18 18:41:20 +01:00
Witold Filipczyk
d393a06f07 [mujs] document.defaultView 2024-01-17 17:12:18 +01:00
Witold Filipczyk
ebb41e9c67 [quickjs] document.defaultView 2024-01-17 17:05:36 +01:00
Witold Filipczyk
5297063bbe [spidermonkey] document.defaultView 2024-01-17 16:55:52 +01:00
Witold Filipczyk
addc4a7c43 [quickjs] location.replace 2024-01-16 18:51:48 +01:00
Witold Filipczyk
4aa0ff661f [mujs] location.replace 2024-01-16 18:45:44 +01:00
Witold Filipczyk
2d4d46f939 [spidermonkey] location.replace
I guess there is something wrong with this function.
2024-01-16 18:39:00 +01:00
Witold Filipczyk
afb2a7da28 [quickjs] location.assign 2024-01-16 17:57:45 +01:00
Witold Filipczyk
65998ab36b [mujs] location.assign 2024-01-16 17:47:04 +01:00
Witold Filipczyk
ebaceedab2 [spidermonkey] location.assign 2024-01-16 17:38:26 +01:00
Witold Filipczyk
103669e825 [html5] Also add NAV element. Refs #282 2024-01-07 20:11:00 +01:00
Witold Filipczyk
94cfc49ce1 [win32] Every mouse DOWN followed by UP
It is rather a workaround, but works for the right button click.
2024-01-07 16:18:54 +01:00
Witold Filipczyk
ef80897185 [html5] Stubs for html_main and html_article. Refs #282 2024-01-07 11:43:18 +01:00
Witold Filipczyk
69edab0036 [libcss] initialize unit_len_ctx with zeroes 2024-01-07 11:41:52 +01:00
Witold Filipczyk
a96b9fba1f [win32] middle and right buttons were swapped
Right-click menu still not functional.
It appears, but disaappers immediately, and "Go back" action is choosen.
2024-01-06 15:51:44 +01:00
Witold Filipczyk
389df54184 Revert "[head] addcrlf". Refs #281
This reverts commit 90d4f17031.
2024-01-06 09:33:40 +01:00
Witold Filipczyk
0b7cdab108 [terminal] Do not draw the right bottom cell
For wineconsole.
2024-01-05 19:29:58 +01:00
Witold Filipczyk
6642ebe509 [win32] Some changes in mouse handling
It is a step forward. There some problems with wheel, the right mouse button.
2024-01-04 18:29:31 +01:00
Witold Filipczyk
84f6a08f83 [kbd] Test commit. Change <= 0 to < 0
I'm trying to debug mouse issues.
2024-01-03 21:37:07 +01:00
Witold Filipczyk
2fdb04a6ab [libcss] bump libcss to 0.9.2 and libdom to 0.4.2
Needs some tweaks. Code is compilable at least.
2024-01-01 17:47:59 +01:00
Witold Filipczyk
f89705df74 [spidermonkey] Bump mozjs dependency to mozjs-115 2024-01-01 13:24:32 +01:00
Witold Filipczyk
378842a349 [quickjs] C only
There are some bugs left.
2023-12-31 16:08:35 +01:00
Witold Filipczyk
4c7364c14e [mujs] Code rewritten to C
Likely some bugs were introduced here.
elinks with mujs suppport can be built by tcc.
2023-12-30 21:42:31 +01:00
Witold Filipczyk
8b5cb79485 [ecmascript] Copy of ecmascript.cpp as ecmascript.c 2023-12-29 20:53:53 +01:00
Witold Filipczyk
3f3a38145a [ecmascript] New try to compile code by C compiler
ecmascript-c.c is compilable by C compilers and ecmascript-c.cpp
which includes ecmascript-c.c is compilable by C++ compilers.
2023-12-29 20:42:21 +01:00
Witold Filipczyk
c473ce5522 [quickjs] quickjs.cpp -> quickjs.c 2023-12-29 19:27:26 +01:00
Witold Filipczyk
6ad38f3814 [mujs] mujs.cpp -> mujs.c 2023-12-29 19:23:50 +01:00
Witold Filipczyk
7de0146ded [ecmascript] localstorage-db.cpp -> localstorage-db.c
This code is pure C. There are some memory leaks.
They will be addressed later.
2023-12-29 18:46:19 +01:00
Witold Filipczyk
78483386c2 [ecmascript] timer.cpp -> timer.c
hash instead of map.
The goal is to get C++ free code for mujs and quickjs.
2023-12-29 18:29:13 +01:00
Witold Filipczyk
447c452339 [download] No need to double check 2023-12-28 13:03:45 +01:00
Witold Filipczyk
fd5e164b8f [download] memory leaks 2023-12-28 13:01:01 +01:00
Witold Filipczyk
204234b921 [memcount] libevent malloc, realloc, free replacement functions 2023-12-26 19:09:32 +01:00
Witold Filipczyk
b1bf9e8dba [libevent] Add SOCK_SHIFT for curl and libevent 2023-12-26 17:04:24 +01:00
Witold Filipczyk
1f4ca1445d [libevent] include event2/event.h instead of event.h 2023-12-26 15:53:22 +01:00
Witold Filipczyk
5211b2d8a1 [curl] fifo_event was unused 2023-12-26 14:57:25 +01:00
Witold Filipczyk
8d0054041b [select] Another try
Set fields of timeout manually.
2023-12-20 20:31:13 +01:00
Witold Filipczyk
f91d214820 [select] This code is problematic.
EINVAL on OpenBSD/i386.
2023-12-20 18:06:20 +01:00
Witold Filipczyk
6c32ce3c61 [gettext] Let it work also on Windows
When elinks.exe is located in the src subdirectory,
.gmo files are read from the po subdirectory.
2023-12-15 10:36:17 +01:00
Witold Filipczyk
93e9ac1b4c [gettext] Revision 1 is also valid
At least I think so.
2023-12-14 21:45:08 +01:00
Witold Filipczyk
dee0b28f97 [spidermonkey] meson.build also was missing 2023-12-10 16:42:32 +01:00
Witold Filipczyk
6f11b9be8b [windows] Fixes for FSP (send and recv) 2023-12-09 19:57:08 +01:00
Witold Filipczyk
2ace5374c8 [cast] cast to intptr_t to silence compiler 2023-12-08 11:14:27 +01:00
Witold Filipczyk
b894447af1 [hash] drop const for key 2023-12-08 11:11:06 +01:00
Witold Filipczyk
0fbec94494 [ssl] Change order of includes
There was compilation failure on win32.
2023-12-07 12:52:34 +01:00
Witold Filipczyk
43dd4f38a0 [c++] undef max and min
There were different definitions of them in sys/cdefs.h
2023-12-07 11:33:39 +01:00
Witold Filipczyk
425d779e15 [terminal] Avoid division by zero. Refs #276 2023-12-07 08:21:13 +01:00
Witold Filipczyk
e538a9f827 [terminal] use fd not 1 for ioctl 2023-12-06 08:21:29 +01:00
Witold Filipczyk
b580d78ba3 [spidermonkey] Makefile was missing 2023-12-04 14:21:21 +01:00
Witold Filipczyk
8badb62c34 [document] I did not test it, but I guess it must be & prepended here 2023-11-29 16:15:34 +01:00
Witold Filipczyk
a5d2119dbf [map] Reimplemented map as hash
Maybe it is slower, but C only.
2023-11-28 19:55:37 +01:00
Witold Filipczyk
e0909362eb [view] this include is only for ecmascript 2023-11-28 15:47:53 +01:00
Witold Filipczyk
3bdb576929 [viewer] unneeded include 2023-11-28 15:45:28 +01:00
Witold Filipczyk
899304d6ef [viewer] form.cpp -> form.c 2023-11-28 15:41:48 +01:00
Witold Filipczyk
c14989ab91 [viewer] link.cpp -> link.c
Moved some code to ecmascript-c.cpp
2023-11-28 15:33:54 +01:00
Witold Filipczyk
88d836355d [viewer] This include was not needed 2023-11-28 15:15:56 +01:00
Witold Filipczyk
7e48d22f51 [viewer] view.cpp -> view.c 2023-11-27 19:14:39 +01:00
Witold Filipczyk
bbf902f426 [viewer] This include was not needed 2023-11-27 18:52:19 +01:00
Witold Filipczyk
8f431a126f [viewer] vs.cpp -> vs.c 2023-11-27 18:34:15 +01:00
Witold Filipczyk
9dedc5779b [dcument] Compilation fix 2023-11-27 18:33:44 +01:00
Witold Filipczyk
bfd3f01d35 [document] document.cpp -> document.c
Moved some code to ecmascript-c.cpp.
2023-11-27 16:38:58 +01:00
Witold Filipczyk
a07f339fd1 [document] get rid of C++ list.
In first place it was implemented in C++ because of memory corruption problems.
2023-11-27 16:26:09 +01:00
Witold Filipczyk
4ecb3fa8bb [main] timer.cpp -> timer.c 2023-11-27 15:08:20 +01:00
Witold Filipczyk
424466740c [document] renderer.cpp -> renderer.c
Moved ecmascript code to ecmascript-c.cpp
2023-11-26 19:47:59 +01:00
Witold Filipczyk
bb137d12e9 [download] download.cpp -> download.c
elinks's hash instead of C++ map.
2023-11-26 19:09:19 +01:00
Witold Filipczyk
db99981ec5 [terminal] Make a copy of filename for hash 2023-11-26 19:00:04 +01:00
Witold Filipczyk
49285684ea [quickjs] Makefile 2023-11-25 18:43:25 +01:00
Witold Filipczyk
0d4f83e94a [quickjs] include 2023-11-25 18:29:32 +01:00
Witold Filipczyk
25027fca0a [dos] doc.cpp -> dos.c 2023-11-25 18:23:18 +01:00
Witold Filipczyk
3d3e61a025 [quickjs] Missing file 2023-11-25 18:21:16 +01:00
Witold Filipczyk
1219e479b5 [session] session.cpp -> session.c 2023-11-25 18:15:24 +01:00
Witold Filipczyk
d606aca351 [terminal] terminal.cpp -> terminal.c
hash from util instead of C++ map
2023-11-25 18:08:46 +01:00
Witold Filipczyk
970245b28a [protocol] protocol.cpp -> protocol.c 2023-11-25 17:06:11 +01:00
Witold Filipczyk
f70c1dc51b [main] module.cpp -> module.c 2023-11-25 14:30:05 +01:00
Witold Filipczyk
009d09ba52 [viewer] action.cpp -> action.c 2023-11-25 14:13:10 +01:00
Witold Filipczyk
fe8d8d6af0 [cache] Renamed cache.cpp -> cache.c 2023-11-25 13:29:23 +01:00
Witold Filipczyk
7acee28e2d [dialogs] Rename info.cpp to info.c
Long term goal is to able compile by only C compiler
if ecmascript is not compiled-in.
2023-11-25 13:11:21 +01:00
Witold Filipczyk
5c3680af05 [spidermonkey] Moved files from ecmascript/libdom/spidermonkey to ecmascript/spidermonkey 2023-11-23 18:13:07 +01:00
Witold Filipczyk
efb4ab6304 [quickjs] Moved files from ecmascript/libdom/quickjs to ecmascript/quickjs 2023-11-23 18:05:23 +01:00
Witold Filipczyk
ad353ebbc8 [mujs] moved files from ecmascript/libdom/mujs to ecmascript/mujs
To be consistent with header files.
2023-11-23 17:52:39 +01:00
Witold Filipczyk
c3edadc2d9 [spidermonkey] Empty finalizers 2023-11-22 20:55:57 +01:00
Witold Filipczyk
fe90abbaec [spidermonkey] Check for NULL 2023-11-22 20:21:26 +01:00
Witold Filipczyk
267e25e908 [spidermoneky] Removed unused parameter from get_form_object 2023-11-22 20:13:23 +01:00
Witold Filipczyk
53522b8946 [color] memcmp for comparison of colors
Weak point is for example:
256 colors, compiled with true colors.
2023-11-21 18:35:13 +01:00
Witold Filipczyk
c3c9041487 [mujs] compilation fixes 2023-11-21 16:37:37 +01:00
Witold Filipczyk
4495873d39 [spidermonkey] These assertions failed 2023-11-21 14:33:19 +01:00
Witold Filipczyk
64343791dd [quikcjs] Removed optimisation
No DupValue. There were errors reported by valgrind
2023-11-20 20:01:56 +01:00
Witold Filipczyk
c9e1dd93cc [mujs] skip NULL forms 2023-11-20 15:52:32 +01:00
Witold Filipczyk
5f3830406e [mujs] ref_count in element 2023-11-20 15:44:59 +01:00
Witold Filipczyk
7c24c0ec47 [spidermonkey] Added ref_count to el_private 2023-11-18 19:34:57 +01:00
Witold Filipczyk
a6a81b9164 [config] PRIdPTR format for OPT_LONG 2023-11-17 21:29:21 +01:00
Witold Filipczyk
125262eac1 [mujs] % PRId64 instead of %ld 2023-11-17 20:46:47 +01:00
Witold Filipczyk
25a859090a [qs_parse] i was unused 2023-11-17 17:22:00 +01:00
Witold Filipczyk
58b0b39200 [hr] char -> unsigned char to avoid warning 2023-11-17 16:04:05 +01:00
Witold Filipczyk
aa7edfc16d [osdep] initialize ret 2023-11-16 19:09:49 +01:00
Witold Filipczyk
dabfe8dbbd [terminal] initialize blockh 2023-11-16 19:03:02 +01:00
Witold Filipczyk
02b644aa64 [terminal] Initialize blockh 2023-11-16 19:00:19 +01:00
Witold Filipczyk
8d93489933 [curl] Download resume for http 2023-11-16 16:24:08 +01:00
Witold Filipczyk
1ff535370e [curl] Added download resume for curl's ftp 2023-11-16 16:08:29 +01:00
Witold Filipczyk
ec9708a87e [document] init_string(&document->text) 2023-11-11 16:34:12 +01:00
Witold Filipczyk
ef1569e24c [dos] Check env CURL_CA_BUNDLE also for non-curl code path 2023-11-10 09:39:59 +01:00
Witold Filipczyk
a76aa91566 [win32] style 2023-11-08 17:33:06 +01:00
Witold Filipczyk
98a9cbf2b7 [windows] handle terminal resize, based on links2 code 2023-11-08 17:29:58 +01:00
Witold Filipczyk
c4add15307 [curl] Check CURL_CA_BUNDLE also for ftps 2023-11-08 13:39:26 +01:00
Witold Filipczyk
388db93244 [curl] Check enviroment variable CURL_CA_BUNDLE 2023-11-08 13:09:57 +01:00
Witold Filipczyk
1042755f7f [windows] Less number of warnings 2023-11-08 12:28:00 +01:00
Witold Filipczyk
3aed9a8fda [lua] compilation fix for Windows
There is no sigsetjmp function on mingw64.
2023-11-08 09:08:54 +01:00
Witold Filipczyk
8164715d0f [select] SOCK_SHIFT for curl under Windows 2023-11-06 19:04:14 +01:00
Witold Filipczyk
d6f7e86623 [windows] build static 2023-11-04 22:02:12 +01:00
Witold Filipczyk
decdfa853c [windows] Compilation fixes 2023-11-04 20:30:25 +01:00
Witold Filipczyk
eba67dc278 [dos] CONFIG_ECMASCRIPT -> CONFIG_QUICKJS
mujs also can be compiled, and does not have check_heartbeats.
2023-11-01 17:19:09 +01:00
Witold Filipczyk
2ac5d5c0b9 [quickjs] Do not include <uchar.h> 2023-10-29 18:37:07 +01:00
Witold Filipczyk
33d119ba2f [memcount] More mem_alloc and mem_free 2023-10-27 21:15:52 +02:00
Witold Filipczyk
d5dc632443 [mujs] memcount mem_realloc and mem_free for mujs
Also commented code in mujs_element_init. It caused only a memory leak.
2023-10-27 20:37:50 +02:00
Witold Filipczyk
263a06396d [document] Free previous document->title if was set 2023-10-27 16:54:18 +02:00
Witold Filipczyk
a476ddd419 [memcount] mem_alloc for quickjs 2023-10-27 11:16:24 +02:00
Witold Filipczyk
10667d2437 [memcount] mem_alloc and others for curl 2023-10-27 11:07:05 +02:00
Witold Filipczyk
3834c52686 [zstd] Added memcount (only for statically linked zstd) 2023-10-26 18:17:16 +02:00
Witold Filipczyk
17b288c935 [spidermonkey] ref_count in heartbeat 2023-10-25 21:09:25 +02:00
Witold Filipczyk
d5787d46b4 [quickjs] reference count in heartbeat.c 2023-10-25 20:59:55 +02:00
Witold Filipczyk
6629f34466 [memcount] CONFIG_DEBUG inside memcount.h 2023-10-25 17:17:08 +02:00
Witold Filipczyk
0b4007fd7e [quickjs] memcount 2023-10-25 17:10:59 +02:00
Witold Filipczyk
dae67eee8a [mujs] Added info when CONFIG_DEBUG 2023-10-24 19:37:16 +02:00
rkd77
a9ea05f0de
Merge pull request #269 from balducci/master
make it build when CONFIG_ECMASCRIPT is undefined
2023-10-24 18:43:41 +02:00
Witold Filipczyk
5d750958dd [info] used times -> calls 2023-10-24 18:38:04 +02:00
gabriele balducci
1112827be6 make it build when CONFIG_ECMASCRIPT is undefined 2023-10-24 18:00:11 +01:59
Witold Filipczyk
1145193290 [curl] Added info about allocations in CONFIG_DEBUG 2023-10-24 17:39:26 +02:00
Witold Filipczyk
007fef1d6c [forms] Temporarily comment assertion 2023-10-24 12:34:27 +02:00
Witold Filipczyk
aeeceaaf83 [ecmascript] mem_calloc instead of calloc 2023-10-24 12:28:00 +02:00
Witold Filipczyk
c753c75f94 [po] New lines at the end of text are "forbidden". 2023-10-24 11:03:52 +02:00
Witold Filipczyk
2c47b22bc4 [libsixel] memcount 2023-10-23 21:54:29 +02:00
Witold Filipczyk
f55e9dd33e [brotli] Added debug info 2023-10-23 20:12:38 +02:00
Witold Filipczyk
a2ae13cf06 [debug] Show info about gzip allocations
Number of callocs from the begining.
Number of active allocations.
Total size of active allocations.
2023-10-23 19:06:21 +02:00
Witold Filipczyk
7185d705de [debug] compilation fixes for -Dwithdebug=true 2023-10-23 15:56:53 +02:00
Witold Filipczyk
f12134c2cf [libdom] unlock cached 2023-10-20 18:04:48 +02:00
Witold Filipczyk
9fc4d8022d [ecmascript] unlock previously locked document 2023-10-20 18:02:41 +02:00
Witold Filipczyk
19cb86aeff [mujs] skip reusing of elements 2023-10-20 16:38:09 +02:00
Witold Filipczyk
9563fef842 [document] check also doc_view->vs 2023-10-20 13:44:41 +02:00
Witold Filipczyk
bc302f11d2 [ecmascript] Refresh frames 2023-10-19 19:16:08 +02:00
Witold Filipczyk
b931536fc3 [mujs] Define location in window.c 2023-10-19 18:03:53 +02:00
Witold Filipczyk
ba33d709de [document] sort links after rewrite of document 2023-10-18 16:34:18 +02:00
Witold Filipczyk
bc597e2b61 [mujs] Alias Date.prototype.toGMTString -> Date.prototype.toUTCString 2023-10-18 16:33:14 +02:00
Witold Filipczyk
ad077babc4 [mujs] Do not enable strict mode 2023-10-18 15:54:15 +02:00
Witold Filipczyk
1a25f30831 [mujs] Slightly modified way of defining window object 2023-10-18 15:23:36 +02:00
Witold Filipczyk
9504926c6b [frames] Do not free doc_view, when toggle html -> plain
I know it is not correct, but at least does not crash.
2023-10-15 16:06:53 +02:00
Witold Filipczyk
ddbc49b6b3 [http] Added REFERER to curl 2023-10-06 15:12:29 +02:00
Witold Filipczyk
2c978637f0 [curl] send_cookies 2023-10-06 14:58:04 +02:00
Witold Filipczyk
235d998a6a [ecmascript] scroll again
scroll3.html works if started as the first page.
2023-10-05 16:42:53 +02:00
Witold Filipczyk
17fecb2aad [spidermonkey] element.checked 2023-10-04 20:54:39 +02:00
Witold Filipczyk
ebae7f3927 [mujs] element.checked 2023-10-04 20:40:55 +02:00
Witold Filipczyk
c56d925ce2 [quickjs] element.checked 2023-10-04 20:32:05 +02:00
Witold Filipczyk
789be0be41 [session] Set referrer based on ses->doc_view not current_frame 2023-09-29 20:18:27 +02:00
Witold Filipczyk
8596d604cc [dom] rewrite cache 2023-09-29 18:51:58 +02:00
Witold Filipczyk
3b233ba711 [libcss] this assertion fails 2023-09-29 17:15:12 +02:00
Witold Filipczyk
5d01bbb05d [spidermonkey] compilation fixes 2023-09-29 16:46:44 +02:00
Witold Filipczyk
7fc8c2088f [document] format_cache implemented as std::list
Slower, but works for my testcase.
2023-09-28 19:44:09 +02:00
Witold Filipczyk
61466065a2 [quickjs] compilation fixes 2023-09-28 14:45:14 +02:00
Witold Filipczyk
ecff39f6c3 [js] memacpy 2023-09-28 14:37:28 +02:00
Witold Filipczyk
446f6de0e0 [quickjs] stracpy to avoid warnings 2023-09-28 14:31:10 +02:00
Witold Filipczyk
42abf0b058 [spidermonkey] clang compilation fixes 2023-09-28 13:27:31 +02:00
Witold Filipczyk
6487a287cf [document] Slightly better handling of string 2023-09-28 12:04:57 +02:00
Witold Filipczyk
98e72e99f3 [document] text as struct string 2023-09-28 11:54:46 +02:00
Witold Filipczyk
e80a2f7014 Merge branch 'master' into router 2023-09-28 10:40:45 +02:00
hedy
7266ac4cbd
[gemini] Use paragraph tags on gemtext empty lines
This patch makes paragraphs separated by an empty new line appear after
an empty new line when rendered in elinks.

Previously, for a gemtext source that looks like this:

    First para
    Second line

    Second para

It renders like this:

    First para
    Second line
    Second para

After this patch, they now render like this:

    First para
    Second line

    Second para

Unfortunately this also adds a </p> to the start of the HTML, as well as
a <p> at the end, both redundant; but since the HTML is parsed and
rendered later on, it does not seem to alter how the document would
look.

    </p><p> First para <br> Second line </p><p> Second para </p><p>

I could possibly add a `first_paragraph` variable and a `i !=
buffer->length` check to remove the first </p> and last <p> in the HTML,
making the HTML source "prettier". But I don't believe that would be too
beneficial, considering the performance tradeoff in executing these two
extra checks for each empty new line encountered.

For testing please see: gemini://hedy.tilde.cafe/tmp/paragraphs.gmi
2023-09-28 15:48:59 +08:00
Witold Filipczyk
5483782949 [session] load_common as separate function
Call it instead of display_timer in delayed_reload
2023-09-27 17:14:01 +02:00
Witold Filipczyk
5175ecd2b7 [libcss] gray75 as default color for text 2023-09-27 10:47:04 +02:00
Witold Filipczyk
a645856fac [libcss] color must be set
Otherwise valgrind shows uninitialized value.
2023-09-26 19:44:34 +02:00
Witold Filipczyk
c3c80cb952 [libdom] cast 2023-09-26 19:38:08 +02:00
Witold Filipczyk
5e5d7f702a [options] Moved was_xml_parsed below framename
Also call display_timer. For framesets
2023-09-26 16:58:13 +02:00
Witold Filipczyk
637bcb725c [quickjs] location 2023-09-25 14:35:53 +02:00
Witold Filipczyk
c9359669bd [spidermonkey] getLocation
Both:
location = url;
location.href = url;
should work.
2023-09-25 13:46:18 +02:00
Witold Filipczyk
4375984708 [js] Distinguish between document.write(ln) and other modifications
Reparse document only for document.write(ln).
2023-09-25 10:52:19 +02:00
Witold Filipczyk
15da44d9ea [libdom] reparse document, when it was modified by js 2023-09-24 17:56:58 +02:00
Witold Filipczyk
78543c55ee [table] skip_script 2023-09-24 17:56:06 +02:00
Witold Filipczyk
81b89946e6 [cookies] dl=0 ok 2023-09-24 10:27:29 +02:00
Witold Filipczyk
773ac97e1b [libdom] For parsed document separate function: dump_xhtml 2023-09-23 19:28:28 +02:00
Witold Filipczyk
b3e77ef53e [js] document is already parsed. No need to check 2023-09-23 18:58:21 +02:00
Witold Filipczyk
1b9983c543 [mujs] element.value 2023-09-22 21:04:24 +02:00
Witold Filipczyk
a6a7345701 [quickjs] element.value 2023-09-22 20:54:24 +02:00
Witold Filipczyk
6ce64c1894 [spidermonkey] element.value 2023-09-22 20:40:19 +02:00
Witold Filipczyk
f461c86ce6 [document] Added body_onkeypress
It is silly, but I want some scripts to work.
2023-09-22 16:37:53 +02:00
Witold Filipczyk
9ca95e1ffe [js] ENTER has code 13 2023-09-21 19:35:52 +02:00
Witold Filipczyk
fb1c70564e [mujs] window.event 2023-09-21 19:06:52 +02:00
Witold Filipczyk
ced7b7b294 [quickjs] window.event 2023-09-21 17:59:47 +02:00
Witold Filipczyk
a9b8dca965 [spidermonkey] window.event 2023-09-21 17:38:56 +02:00
Witold Filipczyk
447aa41dc9 [js] placeholder for onkeypress 2023-09-21 09:30:50 +02:00
Witold Filipczyk
5dc2187450 [libdom] Do not rewrite < and > in scripts 2023-09-20 18:46:38 +02:00
Witold Filipczyk
b0127bec3b [js] unused variable 2023-09-19 21:02:44 +02:00
Witold Filipczyk
4d8de245ad [spidermonkey] element.style (setter) 2023-09-19 20:59:35 +02:00
Witold Filipczyk
b434875c52 [quickjs] element.style (setter) 2023-09-19 20:40:03 +02:00
Witold Filipczyk
6fb1360c01 [mujs] element.style (setter) 2023-09-19 20:19:21 +02:00
Witold Filipczyk
0b7caf4e82 [spidermonkey] element.style (getter) 2023-09-19 17:29:08 +02:00
Witold Filipczyk
b34d1b6b60 [quickjs] element.style (getter) 2023-09-19 16:48:16 +02:00
Witold Filipczyk
e2ea308100 [mujs] element.style (getter) 2023-09-19 16:04:39 +02:00
Witold Filipczyk
79bfb0bc4a [br] Shorter code 2023-09-14 17:57:56 +02:00
Witold Filipczyk
5fbfacbab6 [xhtml] Special case for BR. Refs #266
Rewrite is as <BR/> instead of <BR></BR>.
2023-09-14 17:40:27 +02:00