Re: TreeView - set border on individual cells
- From: Emmanuele Bassi <ebassi gmail com>
- To: cecashon aol com
- Cc: redtux1 gmail com, gtk-app-devel-list list <gtk-app-devel-list gnome org>
- Subject: Re: TreeView - set border on individual cells
- Date: Sat, 6 Apr 2019 20:23:52 +0100
On Sat, 6 Apr 2019 at 20:15, <cecashon aol com> wrote:
The second cairo_t is used so that the rectangle can be lined up to the
cell. If I use the cairo_t in the "draw" callback then the rectangle
doesn't line up.
You're still using:
1. the wrong window to draw on
2. deprecated API
3. a slow rendering path
In general, though drawing *on top* of widgets is not encouraged; you're
either going to break things inside GTK, or your own code will break
because GTK may change something in how widgets are drawn.
If you want to change how a cell is rendered, you can subclass the cell
renderer into your own class and override its own draw function; this way,
you're guaranteed you'll be rendering at the right position.
Ciao,
Emmanuele.
--
https://www.bassi.io
[@] ebassi [@gmail.com]
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]