Commit Graph

81 Commits

Author SHA1 Message Date
RichardHitt 9664b1b7e3 Fix select regression.
Fix selection when part of the selected text is above/below a border.
Also, fix problems uncovered by static analysis.

Fixes #1261.
2015-08-20 00:23:17 +02:00
RichardHitt f7bea16e37 xtext: Fix poor performance with nick indent enabled
This fixes xtext re-rendering multiple times when the
indent width is not sufficient

Fixes #1364
Closes #1367
2015-05-18 06:31:00 -04:00
Arnavion e42da22716 Revert "xtext: Unselect old selection on button press" - breaks clicking URLs to open them.
This reverts commit 8ca96d7ea3.
2015-02-20 02:54:41 -08:00
RichardHitt 8ca96d7ea3 xtext: Unselect old selection on button press
Fixes #943
Closes #1293
2015-02-15 13:17:55 -05:00
Arnavion 9858784eb6 Better project files.
- Output directly to rel\ instead of to bin\ and then copying files over.
- Deduped Win32 vs x64 configs
- Moved some common properties to hexchat.props
- All build intermediates (except htm's intermediates) are no longer emitted in the source directory
2015-02-11 10:01:29 -08:00
TingPing 2a28289314 Don't return 0 in place of NULL 2014-12-31 11:31:17 -05:00
TingPing 83032b1aa3 Use glib for all allocations
- Removes need to check for malloc failure
- Removes need for NULL checks on free
- Adds checks for integer overflows
- Removes some extra memset calls
- Removes chance of mixing libc and glib malloc/free
2014-12-28 06:44:44 -05:00
TingPing aeb5d15871 More consistently include config.h 2014-12-17 18:21:10 -05:00
TingPing 05a6097dc6 Fix copying timestamp with server-time and indent nicks off 2014-11-30 22:33:30 -05:00
TingPing 85557f2416 Fix duplicate timestamps on selection
Fixes #1226
2014-11-30 22:27:00 -05:00
Campbell Barton f83d78dd28 Warning cleanup
- ignoring const
- declarations after statements
- some C files didnt include own headers (risking them getting out of sync)

Closes #1064
2014-11-02 14:41:20 -05:00
RichardHitt 6653582f0a Fix textbox not scrolling to to bottom on resize
Set buf->scrollbar_down conditionally when vertically resizing text window
If resize to enlarge appears to go to last line, set buf->scrollbar_down to be sure.

Fixes #1151
Closes #1171
2014-10-10 13:35:00 -04:00
Farow fd95c729d5 xtext: Add word and line selection modes
Similar to a GtkTextView if you double click you enter word selection mode
and if you triple click you enter line selection mode.
Allowing you to drag and select more than a single character.

Closes #1108
2014-09-01 17:53:03 -04:00
TingPing b8c02f71d9 win32: Use config.h instead of config-win32.h 2014-06-04 10:30:18 -04:00
RichardHitt 5706550cc1 Rework gtk_xtext_selection_draw(), simplify calls to _selection_render()
Fixes #992.
2014-05-31 02:40:28 -07:00
RichardHitt 6fb8cf40e1 Fixes #959. In xtext.c:find_x() return offset to hidden text if appropriate. 2014-05-22 07:06:51 -07:00
RichardHitt 0f828dd74f Add marker-line functionality for scrollback, instant seek.
Fixes #662.
2014-04-02 16:14:45 -07:00
RichardHitt 46e449f110 Correctly scroll down autojoined channels
Fixes #58
2014-03-19 10:31:52 -04:00
RichardHitt 0487daf865 Fix three miscellaneous bugs in gtk_xtext_get_word()
* Use utf8 functions for moving within string
	* Fix memory leak
	* Fix non-indent select problem
2014-03-19 10:31:26 -04:00
TingPing 34cf164aa2 Use a single marshal file for entire project 2014-02-06 20:17:08 -05:00
TingPing 5f7321280e Use a standard GtkScrolledWindow with xtext
Used in maingui, fkeys, text events, rawlog

This also implements the set_scroll_adjustments signal in xtext
2014-02-06 20:17:07 -05:00
RichardHitt 4c1fd3ee67 Fix many many problems in xtext.c related to character width.
* Rework multiline logic to use a GSList, not an array
* Remove all multibyte booleans; everything is potentially multibyte
  - Except for gtk_xtext_get_word(), which needs special attention
* Enhance pango work for bold and italics (attr_list -> attr_lists[4])
* Enhance gtk_xtext_strip_color () to save bold, italics info
* Involve emphasis information in all pixel-width calculations
* Rework find_x () to account for emphasis info in widths

Closes #891
Fixes #872
2014-02-04 21:26:58 -05:00
RichardHitt 007f49c39f Fixes #881 Fix two bugs --
gtk_xtext_find_char() adjust negative y for int typecast
	gtk_xtext_find_x() return out_of_bounds TRUE if line outside windodw
	gtk_xtext_selection_draw() recognize TRUE out_of_bounds
2014-01-29 11:56:23 -08:00
TingPing 093bdd8b1c Fix warning
Leftovers from 38cbabea
2014-01-20 01:25:35 -05:00
TingPing 38cbabea02 Revert GtkObject removal until Gtk3 2014-01-18 21:48:41 -05:00
TingPing ce09cb4a91 Update most deprecated gtk functions 2014-01-18 14:47:17 -05:00
TingPing fa1eb92a7b Update most deprecated gdk functions 2014-01-18 14:47:17 -05:00
TingPing 4319f8009c Don't use SCROLL_HACK on osx 2014-01-14 22:14:27 -05:00
RichardHitt 3821e7a750 Fixes #836. Move to line boundary in _scroll{down,up}_timeout() not _scroll(). 2013-11-14 19:18:07 -08:00
RichardHitt 1aca24f3de Fixes #837. Rewrite gtk_xtext_scroll{down,up}_timeout(). 2013-11-12 15:02:38 -08:00
RichardHitt 811caaaa3d Fixes #836. In gtk_xtext_scroll() always force line integral line boundary. 2013-11-11 12:55:38 -08:00
TingPing 7cf9ea83cb xtext: Get proper text width with attributes 2013-10-26 08:51:50 -04:00
TingPing a72d40284d fix some warnings 2013-10-22 06:21:58 -04:00
TingPing cbf275777c xtext: store palette as GdkColors 2013-10-10 21:02:24 -04:00
TingPing 1f06922803 Revert 2d5cb3ec7b
Scrolling has issues i couldn't easily fix, will get back to
later but lets keep this usable
2013-10-09 13:59:07 -04:00
TingPing 2d5cb3ec7b Round 3 of Gtk accessor functions: xtext 2013-10-08 21:01:07 -04:00
TingPing c537dae7f8 Use Pango Attributes for bold and italics 2013-09-28 23:02:38 -04:00
TingPing 0d2feba69c Revert fast scrolling with background image 2013-09-27 18:23:51 -04:00
TingPing 958f4099f1 Remove overdraw 2013-09-27 17:40:53 -04:00
TingPing 449553ffb0 Replace xtext's transparency with full window transparency
Xtext's transparency barely worked on windows, didn't work on any modern
linux wm and used fake transparency.
This uses gtk's built in window opacity that works on more systems and
is real transparency.
Text area only transparency may return with a transition to cairo, if it
works on Windows.
2013-09-27 17:40:05 -04:00
TingPing f23bda9e46 Remove useless defines
- HEXCHAT
- USE_DB
- SCROLL_HACK
- MOTION_MONITOR
- ITALIC
- COLOR_HILIGHT
2013-09-26 22:34:40 -04:00
TingPing ef73a89139 Remove XFT, SHM, and MMX 2013-09-26 22:31:14 -04:00
Richard Hitt cd825ac735 Improve text repositioning when searchbar string is modified. 2013-09-18 15:25:50 -07:00
TingPing 277732e384 Fix xtext crash in rawlog/text events window
Closes #740
2013-09-15 10:44:55 -04:00
TingPing 46c32952b0 Make formatting more consistent
#719
2013-08-17 20:39:24 -04:00
Farow 9629ca3fd9 Improve cursor behavior
- The cursor doesn't turn into a hand for non-url parts of a word
- Removal of unneeded variable str
2013-08-16 23:05:27 +03:00
Farow 4f77f046d0 Channel url and cursor fix
- Allow colons in channel urls
- Only add the channel part in the context menu
- Fix cursor not changing between separator and url
2013-08-13 04:19:14 +03:00
Diogo Sousa 6e3f05fcc7 Fixed indent: spaces -> tabs. 2013-06-20 19:03:26 +01:00
Richard Hitt d7045e2b61 Fix Fedora-19 Segmentation fault, bugid 968817. 2013-06-15 17:21:55 -07:00
TingPing 0dd9ac2e44 Take two at fixing xtext copying to secondary clipboard 2013-06-07 08:20:36 -03:00