1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-09-28 03:06:20 -04:00
Commit Graph

2970 Commits

Author SHA1 Message Date
Miciah Dashiel Butler Masters
92abd48405 Drop EVENT_TEXTAREA, use EVENT_RESIZE instead
When returning from an external program, unblock_itrm_x in the slave process will send a resize event to the master process for the slave terminal.  In handle_interlink_event, when we receive this resize event, we can check whether we need to call textarea_edit.
2007-09-01 12:46:02 +00:00
Miciah Dashiel Butler Masters
a66f6f8c90 Make the textarea_data member of struct terminal opaque
Move the definition of struct textarea_data back to src/viewer/text/textarea.c.
2007-09-01 12:02:21 +00:00
Miciah Dashiel Butler Masters
ac230ebc08 Add free_textarea_data wrapper for done_textarea_data and use in destroy_terminal
Unexport done_textarea_data.
2007-09-01 11:58:29 +00:00
Miciah Dashiel Butler Masters
6469344727 Export done_textarea_data and call in destroy_terminal to prevent leak
Previously, if a terminal crashed with an external editor open, the struct textarea_data would never be freed
2007-09-01 09:45:56 +00:00
Miciah Dashiel Butler Masters
8dc000e313 Set term_->textarea_data = NULL when taking the pointer in textarea_edit 2007-09-01 09:42:54 +00:00
Miciah Dashiel Butler Masters
d384f93522 Factor done_textarea_data out of textarea_edit 2007-09-01 09:24:22 +00:00
Miciah Dashiel Butler Masters
8c5dc2d161 Factor init_textarea_data out of textarea_edit 2007-09-01 09:20:40 +00:00
Miciah Dashiel Butler Masters
cc67edbe1c Drop @textarea_editor global 2007-09-01 09:10:54 +00:00
Miciah Dashiel Butler Masters
d4c262694b Move pointers to struct textarea_data from linked-list to terminal structure 2007-09-01 09:02:01 +00:00
Witold Filipczyk
7726e33b0a bug 181: Simplification. Reverted changes causing incompatibility. 2007-09-01 09:00:36 +00:00
Miciah Dashiel Butler Masters
1000f88748 bug 181: Allow edit textareas using an external editor on slave terminals.
Added EVENT_TEXTAREA used to notify the master terminal
about end of execution of an external program on a slave terminal.
The format of data sent to the master terminal by exec_on_slave_terminal
has changed. Now after 0, fg the value of term is sent.
Therfore this release of ELinks is incompatible with previous releases.

Patch by Witold Filipczyk, taken from his witekfl branch.

Conflicts:

	src/viewer/text/textarea.c
2007-09-01 09:00:33 +00:00
Petr Baudis
c4fbd87f23 CSS: Add partial support for font-size property
font-size: <length> is now supported. Note that its effect is completely
invisible per se, however the resulting fontsize becomes base value for all
other length values of any properties inside the element using the em or ex
units.
2007-09-01 03:21:18 +02:00
Petr Baudis
85cf6358c3 CSS: Support for parsing length values (CSS2 4.3.2) 2007-09-01 02:41:22 +02:00
Petr Baudis
7cfd863696 CSS: Yield unit as separate token for CSS_TOKEN_DIMENSION 2007-09-01 01:44:56 +02:00
Petr Baudis
9948f01a0e CSS: Parse em and ex values as CSS_TOKEN_LENGTH
...instead of separate tokens. Seems to make no sense.
2007-09-01 01:38:33 +02:00
Petr Baudis
09c31e2b7d Merge branch 'master' of /srv/git/elinks into dom 2007-08-31 15:55:46 +02:00
Jonas Fonseca
8489f04cc9 renderer: Fix unnecessary inclusions of document/html/renderer 2007-08-31 15:43:56 +02:00
Jonas Fonseca
5d34b4bff6 Move find_tag to document/document 2007-08-31 15:43:54 +02:00
Miciah Dashiel Butler Masters
69cf0d06e2 get_opt_: only look for a domain-specific option if no session-specific one found 2007-08-31 09:48:58 +00:00
Miciah Dashiel Butler Masters
3dbdde0f8f Fix RSS rendering
Fix inverted boolean logic from commit 8e954e9f61 'rss: check for allocation failure of struct rss_renderer' that totally broke RSS rendering.
2007-08-31 00:08:19 +00:00
Miciah Dashiel Butler Masters
9f6ce80da3 Add config/domain.[ch] (doh!) 2007-08-30 23:36:20 +00:00
Miciah Dashiel Butler Masters
f04bc1c7d1 init_template_by_style: collapse some case statements
After commit b66d2bec67 'document: Unify text style -> screen attribute handling', the case statements for CSS_PT_FONT_WEIGHT, CSS_PT_FONT_STYLE, and CSS_PT_TEXT_DECORATION all have common code and therefore collapse nicely.
2007-08-30 23:31:20 +00:00
Petr Baudis
204b2071fc HTML DOM: Separate per-element code to elements.* 2007-08-31 00:43:53 +02:00
Miciah Dashiel Butler Masters
5191ed82a1 Move domain-specific options code to config/domain
For great modularity!
2007-08-30 22:03:14 +00:00
Petr Baudis
361d3892c0 HTML DOM: Fix domparser.h include guard 2007-08-30 23:55:56 +02:00
Petr Baudis
e1cc925f27 Merge branch 'master' of /srv/git/elinks into dom 2007-08-30 23:52:31 +02:00
Petr Baudis
e7b4335f21 HTML DOM: Use push_attribute() only for generic attributes
Element-specific attributes should be handled in element-specific code.

Moves already-existing HTML_ATTRIBUTE_HREF handling to element_begins()'s new
HTML_ELEMENT_A branch.
2007-08-30 23:51:35 +02:00
Miciah Dashiel Butler Masters
7f247ec293 Factor get_domain_option_from_session out of get_opt_. 2007-08-30 21:50:55 +00:00
Miciah Dashiel Butler Masters
d9ee9464f4 If it still doesn't work, I'll try compiling it before committing the next attempt. 2007-08-30 21:48:58 +00:00
Miciah Dashiel Butler Masters
7a96a2eda9 Fix a build error from the last change to textarea_edit
Just a silly thinko.
2007-08-30 21:48:03 +00:00
Petr Baudis
e52316c786 Merge commit 'origin' into dom 2007-08-30 23:43:07 +02:00
Miciah Dashiel Butler Masters
860d3cc5ef Suppress a warning about an uninitialised value in parse_set_common 2007-08-30 21:42:57 +00:00
Petr Baudis
fa1c7ae68c Merge commit 'origin' into dom
Conflicts:

	src/document/html/parser.c
2007-08-30 23:39:35 +02:00
Miciah Dashiel Butler Masters
bfe6243bc1 Allow session- or domain-specific settings for document.brose.forms.editor 2007-08-30 21:32:21 +00:00
Petr Baudis
89c0cba973 Merge branch 'dom' of /srv/git/elinks into dom 2007-08-30 23:29:32 +02:00
Petr Baudis
c6ecc29895 DOM HTML: Just pass html_context to get_dom_*attr_uri() 2007-08-30 23:29:30 +02:00
Jonas Fonseca
190f46c87d DOM HTML: Initial support for <title> tags
The render now prospones converting/using the title
passed to init_html_parser until after formatting.
This allows the DOM HTML parser to pick it up and set
it.
2007-08-30 23:25:57 +02:00
Miciah Dashiel Butler Masters
0e0bacf0d3 Merge branch 'master' of ssh://pasky.or.cz/srv/git/elinks
Conflicts:

	src/document/options.c
2007-08-30 21:13:43 +00:00
Miciah Dashiel Butler Masters
91947860f2 Check session- and domain-specific settings for many options
Pass the session with some get_opt_* calls.  These are the low-hanging fruit.  Some places will be difficult because we don't have the session or for other reasons.
2007-08-30 21:11:51 +00:00
Miciah Dashiel Butler Masters
360b4ebfee textarea_edit: convert unnecessary checks to assertions
If @op == 0, then @fs_, @doc_view_, @link_, and @term_ should all be set.  Assert them instead of checking them with if statements.
2007-08-30 21:09:14 +00:00
Miciah Dashiel Butler Masters
06adbbc524 Add domain-specific options saving and look-up
Note that this is the infrastructure, but all relevant get_opt_* calls must be changed to pass the session so that the domain-specific options are looked up.

Add @want_domain parameter to parse_set_common and read in the domain-name if the flag is set.

Add parse_set_domain wrapper for parse_set_common.

Add "set_domain" configuration directive with the following syntax: set_domain domain option = value

Modify create_config_string and smart_config_output_fn to spit out domain-specific option trees.

Add @smart_config_output_fn_domain global variable to facilitate this.

Define structure domain_tree and define list @domain_trees.

Add routine get_domain_tree to find or, if necessary, create the shadow tree for the given domain name.

Add routine get_domain_option search for an option in all domain shadow-trees and return the option in the best matching domain tree.

Modify get_opt_ to use get_domain_option to check for domain-specific options.

Add clean-up routine done_domain_trees, called on exit, to free any domain trees.
2007-08-30 21:04:31 +00:00
Jonas Fonseca
1f4a44e869 DOM: Fix crash in get_dom_node_child on NULL node list 2007-08-30 22:41:44 +02:00
Miciah Dashiel Butler Masters
5ada24f3ef update_cache_document_options: take @ses and pass it to get_opt calls
change_hook_active_link: pass update_cache_document_options @ses.

Now when changing the global settings, it will not simply copy the new values for the global settings to the document-options cache, but also check session-specific settings.  This doesn't really matter yet, since the options in question can't be set on a per-session basis, but is in preparation for future changes.
2007-08-30 19:19:57 +00:00
Jonas Fonseca
05655b53c4 DOM HTML: Add support <a href="..."> links 2007-08-30 20:49:47 +02:00
Jonas Fonseca
061f290465 DOM HTML: Add support for <base href="..." /> 2007-08-30 18:22:25 +02:00
Petr Baudis
f1358e8d0d HTML DOM: Make STYLE and SCRIPT display: none 2007-08-30 12:36:59 +02:00
Petr Baudis
11c3355957 Merge commit 'origin/dom' into dom 2007-08-30 12:31:25 +02:00
Petr Baudis
8ebbd698fd CSS: Support display: none optionally
It is always by default off, no user option to turn it on is available (that's up to Miciah). HTML DOM turns it on for its usage since it's fully CSS-driven.
2007-08-30 12:27:57 +02:00
Petr Baudis
ca38889ce8 document/html: Make invisible generic element attribute
...instead of having it Mikuparser-specific.
2007-08-30 12:23:49 +02:00
Jonas Fonseca
736598b6e7 HTML DOM: Add support for using CSS style elements 2007-08-30 12:16:26 +02:00