Vincent Sanders
1bbc9a485e
remove unecessary includes
2014-10-13 08:07:58 +01:00
Michael Drake
31def6a338
Add rudimentary support for resizing.
...
- Currently only libnsfb's SDL surface supports resizing.
- Flickers like crazy while resizing. Possibly because the SDL
surface is not set to use double buffering.
- The internal widget library, fbtk, was never intended for this,
as such it has no knowledge of how a widget should be positioned
with respect to its parent.
This means the top level window has to track everything and move
them itself.
2014-07-26 22:12:55 +01:00
Michael Drake
4cbc56ebc1
Add Unicode support to internal font.
...
+ Now contains more glpyhs (was previously limited to cp-1252).
+ When a glyph is unavailable, the codepoint is now rendered.
+ Added glyph data file.
+ Added converter to generate the font's .c file from the data.
TODO:
The generated file is currently checked into the repo, but it
should be generated as part of the build process, in the
build-* directory.
To update the generated source file, first build the converter:
$ gcc -O2 -Wall framebuffer/convert_font.c -lm \
-o build-Linux-framebuffer/tools/convert_font
And then use it to generate the souce file:
$ build-Linux-framebuffer/tools/convert_font \
framebuffer/res/fonts/glyph_data \
framebuffer/GEN_font_internal.c -v
The converter's usage is:
convert_font [options] <in_file> <out_file>
See convert_font --help for more details.
2014-05-06 21:31:05 +01:00
Michael Drake
e1a96ecfe1
Register destruction callback to free text widget text.
2013-10-23 19:58:20 +01:00
Michael Drake
fe67bd95d7
There must be a next widget for swap_siblings.
2013-09-05 14:24:17 +01:00
Michael Drake
c56560c2ac
Suppress most fbtk logging when FBTK_LOGGING is unset.
2013-08-29 12:28:37 +01:00
Michael Drake
5ca6862a87
FONT_SIZE_SCALE is for preserving fractional parts, so use it properly.
2013-08-29 12:04:37 +01:00
Michael Drake
7af0614202
Make delete line key enum value name less missleading. (Doesn't cut to clipboard.)
2013-02-11 10:34:06 +00:00
Michael Drake
5f7a3a7ada
Widget can't be NULL.
2012-10-11 14:07:22 +01:00
Michael Drake
84e1bf89d9
Add OSK icon.
2012-09-28 19:52:21 +01:00
Michael Drake
53a379ea45
Squash warning.
2012-08-10 12:17:34 +01:00
Michael Drake
126141a52c
Ensure text is at the right height for Freetype and Internal fonts.
2012-08-08 14:04:57 +01:00
Michael Drake
b238791002
Use enum instead of magic numbers for tracking key modifier states. Pass special keys to core (e.g. WORD_LEFT, SELECT_ALL, etc).
2012-08-01 14:47:20 +01:00
Michael Drake
46527795db
Pass pointer hotspots to libnsfb.
2012-08-01 12:52:46 +01:00
Michael Drake
d84ad62a04
Scroll text in writable text widget so caret is always in view.
2012-08-01 09:29:26 +01:00
Michael Drake
465ebb2c7b
Only writable text widget needs caret rendering.
2012-08-01 09:16:25 +01:00
Michael Drake
9e3db46b67
Handle CTRL modifier too. CTRL with cursor left/right is same as SHIFT. CTRL+U clears writable.
2012-07-31 22:55:08 +01:00
Michael Drake
21ce8800b8
Cursor left/right keys plus modifier move caret to extrems.
2012-07-31 22:40:47 +01:00
Michael Drake
75cc4a06be
Factor out some repeated code.
2012-07-31 22:30:39 +01:00
Michael Drake
53183b2411
Make text input widget remove caret on "strip focus" event.
2012-07-31 22:18:44 +01:00
Michael Drake
72cb5b6ea4
Add widget callback for getting stripped of focus. Call it in the input setter, on previous input holder.
2012-07-31 22:14:48 +01:00
Michael Drake
daa47fce52
Use setter when giving clicked input focus.
2012-07-31 21:49:01 +01:00
Michael Drake
2999410af6
When a text input widget has its text set, and it has the caret, move the caret to the end.
2012-07-31 21:04:20 +01:00
Michael Drake
140795500c
Claim, position, and render caret in text input widget. Currently does not remove caret when input widget is stripped of focus (because widget doesn't know).
2012-07-31 20:43:43 +01:00
Michael Drake
941a48dabd
When setting fbtk caret, register callback for redrawing caret removal.
2012-07-31 20:40:14 +01:00
Michael Drake
4125a8afdf
Remove strlen from redraw functions.
2012-07-31 15:18:25 +01:00
Michael Drake
45b9d96678
Add support for editing text input widget contents from arbitrary position in string (instead of just end).
2012-07-31 15:13:52 +01:00
Michael Drake
90b0c48bb2
Split out common code to generate a font style for text input widget.
2012-07-31 14:06:57 +01:00
Michael Drake
8db6d74bcb
Add basic awareness of text input caret to ftbk and functions to get/set caret pos.
2012-07-31 14:04:12 +01:00
Michael Drake
41f88e6937
Scrollbar behaviour fixes.
...
Stop scrollbar sliding at different rate from pointer.
Stop jump on drag start when scrollbar position indicator isn't at zero.
2012-07-27 14:05:13 +01:00
Michael Drake
382c2f2289
Only warp pointer once for a sequence of consecutive move events. Further reduces lag when dragging scrollbar.
2012-07-26 23:14:27 +01:00
Michael Drake
514bee5786
Handle consecutive queued mouse move events together. Reduces pointer lag when busy.
2012-07-26 22:38:38 +01:00
Vincent Sanders
820312eb35
Update for modified libnsfb API
...
Make thumbnailing work
svn path=/trunk/netsurf/; revision=13159
2011-11-21 08:45:08 +00:00
Michael Drake
eddae6af06
Remove plotter table global. Pass a redraw context around redraw functions. Knockout could be handled better. Note: untested on most front ends.
...
svn path=/trunk/netsurf/; revision=12543
2011-06-30 15:48:07 +00:00
Vincent Sanders
06764ea9f0
add control of fbtk text widget padding
...
svn path=/trunk/netsurf/; revision=12116
2011-03-21 07:51:37 +00:00
John Mark Bell
d945884cb1
Fix font sizing in text widget
...
svn path=/trunk/netsurf/; revision=12016
2011-03-13 10:52:09 +00:00
Vincent Sanders
30a92ed4e6
remove malloc.h anachronism
...
svn path=/trunk/netsurf/; revision=11227
2011-01-06 09:24:14 +00:00
Vincent Sanders
7a3a96045c
fix off by 1 in previous commit
...
svn path=/trunk/netsurf/; revision=10958
2010-12-04 14:30:08 +00:00
Vincent Sanders
4cf27ef338
Stop cursor leaving the root widget and causing a segfault (Found by tlsa)
...
svn path=/trunk/netsurf/; revision=10957
2010-12-04 14:24:53 +00:00
Michael Drake
71ea71540a
Give the browser window widget input focus by defualt on startup.
...
svn path=/trunk/netsurf/; revision=10948
2010-11-20 18:50:45 +00:00
Michael Drake
908da609e7
Make click action happen on release.
...
svn path=/trunk/netsurf/; revision=10947
2010-11-20 17:27:36 +00:00
Vincent Sanders
60fc5bab4f
add explicit inlude for varargs
...
svn path=/trunk/netsurf/; revision=10678
2010-08-03 10:16:41 +00:00
John Mark Bell
5bebf2f2fc
Merge branches/vince/netsurf-fbtk-rework to trunk.
...
svn path=/trunk/netsurf/; revision=10605
2010-07-07 18:08:17 +00:00