1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-08-25 21:44:47 -04:00
Commit Graph

1669 Commits

Author SHA1 Message Date
Kalle Olavi Niemitalo
be9660f7d0 Make all instances of struct widget_ops const.
And widget_type_to_ops[] too.
2007-01-28 14:41:40 +02:00
Kalle Olavi Niemitalo
d40cccef0f Make widget.ops point to const. 2007-01-28 14:38:53 +02:00
Kalle Olavi Niemitalo
3756bec9e0 get_opt_rec, get_opt_rec_real: Let name point to const. 2007-01-28 14:01:24 +02:00
Kalle Olavi Niemitalo
33b2db7053 toggle_success_msgbox: Call option_changed; was a TODO.
This change assumes that option change hooks allow a NULL session.
The only one that did not was change_hook_css, which I fixed in
commit 4adcae682f.
2007-01-28 14:00:14 +02:00
Kalle Olavi Niemitalo
ff4c103a78 Bug 827, display_codepage: Call option_changed.
This change allows screen_driver_change_hook to detect that the
charset has been changed to UTF-8 and set screen_driver.utf8 = 1.
redraw_screen then calls get_screen_driver, which propagates the flag
to terminal.utf8.  That in turn avoids an assertion failure in
handle_interlink_event.
2007-01-28 14:00:06 +02:00
Kalle Olavi Niemitalo
5367209702 mem_align_alloc__, add_bytes_to_string__: Let file point to const. 2007-01-28 02:12:39 +02:00
Kalle Olavi Niemitalo
fd27919f91 add_format_to_string: Let format point to const. 2007-01-28 02:05:52 +02:00
Kalle Olavi Niemitalo
a4293ed606 string_concat: Assume all variadic arguments point to const. 2007-01-28 02:04:00 +02:00
Kalle Olavi Niemitalo
66614acbc0 add_file_to_string: Let filename point to const. 2007-01-28 01:50:06 +02:00
Kalle Olavi Niemitalo
f47bdd76d6 init_string__: Let the file parameter point to const. 2007-01-28 01:46:30 +02:00
Kalle Olavi Niemitalo
0ba497b0d4 xstrcmp: Make both parameters point to const. 2007-01-28 01:43:49 +02:00
Kalle Olavi Niemitalo
0ee76a0ef3 straconcat: Assume all arguments point to const. 2007-01-28 01:42:08 +02:00
Kalle Olavi Niemitalo
03ccf0b2b1 add_to_strn: Let the src parameter point to const. 2007-01-28 01:39:45 +02:00
Kalle Olavi Niemitalo
ac339cf5e5 elinks_ulongcat: Make the static strings const.
And simplify an expression to avoid a cast.
2007-01-28 01:28:44 +02:00
Kalle Olavi Niemitalo
ada3858372 color_specs: Make const. 2007-01-28 01:13:53 +02:00
Kalle Olavi Niemitalo
0484f68b69 get_color_string: Return a pointer to const. 2007-01-28 00:52:21 +02:00
Kalle Olavi Niemitalo
add2a5d1b5 add_quoted_to_string: Make the src parameter point to const. 2007-01-28 00:20:59 +02:00
Kalle Olavi Niemitalo
4adcae682f change_hook_css: Don't use the ses parameter.
It might be NULL.
2007-01-27 22:33:02 +02:00
Kalle Olavi Niemitalo
233c59b9c2 l_set_option: Correct the args to option_changed().
Should have been in commit 2e5488ba3d.
2007-01-27 22:31:47 +02:00
Kalle Olavi Niemitalo
90f1fc5a62 src/Makefile: Add a TAGS target. 2007-01-27 21:03:09 +02:00
Kalle Olavi Niemitalo
6a1d21441e Document the parameters of change_hook_T. 2007-01-27 20:34:18 +02:00
Kalle Olavi Niemitalo
2e5488ba3d option_changed: Merge the 2nd and 3rd parameter.
All callers were passing the same value for both.
2007-01-27 19:52:49 +02:00
Kalle Olavi Niemitalo
7bfd9703d9 toggle_option: Remove an obsolete comment.
option_changed already calls the change hooks so there's no need to
have a TODO comment about calling them.
2007-01-27 19:49:19 +02:00
Kalle Olavi Niemitalo
22f7468013 Make arrays of option change hooks const. 2007-01-27 19:00:47 +02:00
Kalle Olavi Niemitalo
ba5f683dcb l_set_option: Use option_changed() instead of inline code. 2007-01-27 18:41:57 +02:00
Kalle Olavi Niemitalo
f4709c3794 Bug 882: Replace C1 controls with spaces in UTF-8 to the terminal. 2007-01-27 11:12:22 +02:00
Kalle Olavi Niemitalo
564a6b9602 Bug 882, add_char_data: Document the charsets being used. 2007-01-27 10:25:51 +02:00
Kalle Olavi Niemitalo
65645624b4 cp1250, cp1257: Don't map undefined bytes to U+0000. 2007-01-27 09:58:18 +02:00
Kalle Olavi Niemitalo
5882ec0ce7 Make color256_seqs and color_true_seqs const. 2007-01-25 01:04:19 +02:00
Kalle Olavi Niemitalo
649f470fe5 add_string_to_string: Make the "from" string const. 2007-01-25 00:33:17 +02:00
Kalle Olavi Niemitalo
61520b9040 Make inactive screen drivers const. 2007-01-25 00:21:45 +02:00
Kalle Olavi Niemitalo
11006800b5 Make struct strings const in underline mode setup and teardown. 2007-01-25 00:11:38 +02:00
Kalle Olavi Niemitalo
c62e23c161 Make struct strings const in frame mode setup and teardown. 2007-01-25 00:09:07 +02:00
Kalle Olavi Niemitalo
8dd400d49f Make frame translation tables const. 2007-01-25 00:05:36 +02:00
Kalle Olavi Niemitalo
34c636026d draw_line: Make it more obvious that line points into an array. 2007-01-24 23:15:07 +02:00
Kalle Olavi Niemitalo
3b7c021254 Comment changes only (about charsets in terminals). 2007-01-24 23:11:17 +02:00
Kalle Olavi Niemitalo
448f1b55cd Make some small arrays const. 2007-01-24 23:08:25 +02:00
Kalle Olavi Niemitalo
18771fdedb Bug 924, my_timegm: Added a comment about 2100 not being a leap year. 2007-01-13 15:38:02 +02:00
Kalle Olavi Niemitalo
01fdf6c4d3 Bug 923: Added comments about potential time_t truncation.
And removed Miciah's portability question; MSVC++2005 already
has a time_t longer than long, so assuming that time_t is long
is surely not portable.
2007-01-13 15:26:21 +02:00
Kalle Olavi Niemitalo
9385c93ffd Move README.timegm to the same directory as date.c. 2007-01-13 10:01:51 +02:00
Kalle Olavi Niemitalo
f0dfd0504f Route time_t-to-string conversions via time_print_T and TIME_PRINT_FORMAT.
The previous code just printed time_t directly with "%ld".  Now it
instead first casts to time_print_T (currently long) and then formats
with TIME_PRINT_FORMAT (currently "ld").  So the varargs will now
always match with the format string, even if time_t is longer than
long.  This still doesn't correctly format time_t values larger than
LONG_MAX, though.  But now it is at least easier to find some of the
places that need to be changed to support that.

I located these time_t-to-string conversions by searching for
str_to_time_t, expires, and last_visit.  There are still more places
that assume every interesting time_t value fits either in 32 bits or
in a long, e.g. in the cookie editor and in the ECMAScript interface.

Inspired by bug 6.
2007-01-12 23:47:45 +02:00
Kalle Olavi Niemitalo
f796051b4c Bug 921, add_document_to_string: Fixed the UTF-8 half of the code.
* Recompute the pos variable for each cell, rather than just once per line.
  This fixes the bug that only the first cell was being examined.

* Moved the bulk of the code outside the "if (frame && data >= 176 &&
  data < 224)" conditional.  This fixes the bug that only frame
  characters were being added to the string.

* If the cell has UCS_NO_CHAR in it, don't add that to the string.

* Call encode_utf8 even for characters that originated from a frame.
  This does not matter yet but will be correct if the function is
  later changed to use the Unicode line-drawing characters for frames.
2007-01-07 00:09:34 +02:00
Kalle Olavi Niemitalo
06f058f5e8 Bug 752: Rearrange the docstrings of color-mode options.
In the elinks.conf.5 manual page, the text below the list of modes was
getting included in the last list item.  This appears to be a design
error in AsciiDoc.  Work around it by moving the text above the list.
2007-01-06 23:40:18 +02:00
Witold Filipczyk
1e8f8aa4a6 warning: ctext is used only with CONFIG_UTF8. 2007-01-03 21:55:39 +02:00
Kalle Olavi Niemitalo
a577455b24 Revise comments in struct codepage_desc and struct conv_table. 2007-01-03 07:32:00 +02:00
Kalle Olavi Niemitalo
455ea77ead Make strings[] and no_str[] const. 2007-01-02 21:40:14 +02:00
Kalle Olavi Niemitalo
1668d78998 Make cp2utf8 return a pointer to const. 2007-01-02 21:39:34 +02:00
Kalle Olavi Niemitalo
62d321fb31 Make add_utf8 accept a pointer to const. 2007-01-02 21:36:03 +02:00
Kalle Olavi Niemitalo
176bbe83b6 Make input data and source file names const in memacpy and stracpy. 2007-01-02 21:26:55 +02:00
Kalle Olavi Niemitalo
882d179fc8 Make many string parameters const in the memory leak detector. 2007-01-02 21:25:20 +02:00