Michael Natterer
26d0035be0
app: draw guides using GimpCanvasItems
...
- Add signals GimpImage::guide_added(), removed() and moved()
- Remove singal GimpImage::update_guide()
- Adapt core code to emit the new signals instead of update_guide()
- Have the shell connect to the new signals and update guide canvas
items as needed
- Remove gimp_display_shell_draw_guides()
2010-10-01 10:34:15 +02:00
Michael Natterer
3b4f2ec94c
app: add a GimpCanvasProxyGroup that will be used for guides
2010-10-01 10:33:39 +02:00
Michael Natterer
07051535da
app: remove GimpImage signal "update-sample-point"
2010-10-01 09:27:57 +02:00
Michael Natterer
6a2785173d
app: port GimpSamplePointEditor to the "sample-point-moved" signal
2010-10-01 09:27:57 +02:00
Michael Natterer
0c613ba87d
app: port sample point drawing to GimpCanvasItems
...
- Add GimpImage signal "sample-point-moved" and emit it when needed
- Let the shell connect to the sample point add, remove and move signals
and update the canvas items accordingly
- Remove gimp_display_shell_draw_sample_points()
2010-10-01 09:27:57 +02:00
Michael Natterer
0f73269484
app: remove "item" parameter from gimp_canvas_proxy_group_remove_item()
2010-10-01 09:27:57 +02:00
Michael Natterer
75b4c8096f
app: add a proxy group which will keep sample point canvas items
2010-10-01 09:27:57 +02:00
Michael Natterer
f6314b4896
app: add GimpCanvasProxyGroup
...
which is a group that keeps a mapping between arbitrary pointers and
canvas items. No MVC whatsoever yet, just a simple hash table.
2010-10-01 09:27:57 +02:00
Mukund Sivaraman
14f9074675
Remove unused code
2010-09-30 23:01:33 +05:30
Michael Natterer
bab2c37f48
app: don't include "core/gimpsamplepoint.h"
2010-09-30 13:28:04 +02:00
Sven Neumann
2a67bfcb10
app: document the new display title option
2010-09-30 10:14:43 +02:00
Michael Natterer
26f6f2992a
app: remove GIMP_SAMPLE_POINT_DRAW_SIZE from gimpsamplepoint.h
...
and add it to gimpcanvassamplepoint.c, it doesn't need to be public
any longer.
2010-09-30 10:12:15 +02:00
Mukund Sivaraman
f03cf53e0c
Convert tabs to spaces in last commit
2010-09-30 12:54:26 +05:30
Mukund Sivaraman
fee8f4008e
Avoid overflow in expression
2010-09-30 12:47:19 +05:30
Michael Natterer
ad331d5626
app: minor cleanup in gimp_display_shell_expose_item()
2010-09-30 09:05:55 +02:00
Michael Natterer
7f1cadddd0
app: use temporary canvas items for exposing guides and sample points
...
and remove gimp_display_shell_expose_guide() and _sample_point().
2010-09-30 09:02:36 +02:00
Bogdan Szczurek
aa47dd22f0
app: Support 'M' for 'megapixels' in image title format string
2010-09-30 08:07:20 +02:00
Michael Natterer
2ced18cc87
app: add gimp_draw_tool_add_sample_point()
...
and use it in the color tool. Also rename
gimp_draw_tool_add_guide_line() to gimp_draw_tool_add_guide().
2010-09-30 02:03:16 +02:00
Michael Natterer
cbd1d8cd51
app: remove gimp_display_shell_draw_sample_point()
...
and draw all sample points in gimp_display_shell_draw_sample_points().
2010-09-30 01:37:28 +02:00
Michael Natterer
f5750647c1
app: use a GimpCanvasSamplePoint to draw the hovered sample point
2010-09-30 01:32:34 +02:00
Michael Natterer
0d11be8fed
app: add a canvas sample point item class
...
and use it in gimp_display_shell_draw_sample_point().
2010-09-30 01:14:23 +02:00
Michael Natterer
50efb96222
app: remove empty GimpTool::control() implementation
2010-09-30 00:40:42 +02:00
Michael Natterer
a8259996e4
app: simplify the drawing code
...
by using gimp_draw_tool_add_guide_line() for the active guide too.
2010-09-30 00:39:15 +02:00
Michael Natterer
d3e2db88bb
app: restart the draw tool after moving a guide
...
so the dropped guide is highlighted. Also don't uselessly stop/start
the draw tool in each oper_update(), only do so when the display
changes.
2010-09-30 00:29:11 +02:00
Michael Natterer
9d36984d37
app: remove the now obsolete gimp_display_shell_draw_guide()
...
and draw the guides in gimp_display_shell_draw_guides().
2010-09-30 00:23:06 +02:00
Michael Natterer
89af8f4143
app: use a GimpCanvasGuide to display the hovered guide
...
And don't call any shell draw functions directly any longer.
2010-09-30 00:18:00 +02:00
Michael Natterer
5a4bcb8c3d
app: use a temporary GimpCanvasGuide to draw guides guides
2010-09-30 00:02:21 +02:00
Michael Natterer
50755d81f3
app: override GimpCanvasItem::stroke() and optionally stroke in guide style
2010-09-30 00:01:31 +02:00
Michael Natterer
238683e7d6
app: add gimp_canvas_item_get_highlight()
2010-09-29 23:46:36 +02:00
Michael Natterer
7b5316825c
app: turn GimpCanvasItem's stroke() and fill() into virtual functions
2010-09-29 23:40:45 +02:00
Michael Natterer
1f8a835e40
app: fix GimpCanvasBoundary's extents
2010-09-29 23:24:01 +02:00
Mukund Sivaraman
c83294f4ce
Minor coding style fix
2010-09-30 01:56:02 +05:30
Michael Natterer
fe5b6eddc0
app: indentation
2010-09-29 22:20:02 +02:00
Michael Natterer
7edfa2ca54
app: start an infrastructure where the shell keeps around its canvas items
...
- Invalidate the proper area when an item gets added or removed.
- Draw the kept canvas items instead of calling a draw tool function.
- The draw tool now sets its item on the shell.
2010-09-29 22:12:01 +02:00
Michael Natterer
81cfb44047
app: use a GimpColorPanel not a GimpColorButton in the text style editor
...
so we get proper color previews in the popup menu.
2010-09-29 21:14:51 +02:00
Michael Natterer
42e137fc74
app: rename gimp_display_shell_draw_area() to draw_image()
2010-09-29 20:58:13 +02:00
Sven Neumann
2ef259cd20
app: use GimpRGB as mask color
...
Instead of passing GimpChannelType as mask color to
gimp_display_shell_set_mask(), change that function to accept a
GimpRGB color.
Adapt GimpForegroundSelectTool, the only user of the display mask
feature, to this change.
2010-09-29 20:35:00 +02:00
Sven Neumann
a7413bd784
app/display: implement drawing of selection mask
...
Use cairo_mask_surface() to render the selection mask (as used by
the foreground selection tool).
2010-09-29 20:35:00 +02:00
Sven Neumann
1eb77f6360
app/display: refactor RenderInfo code
2010-09-29 20:34:59 +02:00
Sven Neumann
375567df6f
app/display: sprinkle render code with const qualifiers
2010-09-29 20:34:59 +02:00
Sven Neumann
b3182be59c
app/display: remove obsolete includes
2010-09-29 20:34:59 +02:00
Sven Neumann
260c8560e4
app: remove gimp_display_shell_render_{init,exit}
...
The functions had become mostly obsolete and we can just use a
static scratch buffer for rendering.
2010-09-29 20:34:59 +02:00
Sven Neumann
d5d5f4fb3f
app/display: adjust a comment to reflect the current state of the code
2010-09-29 20:34:59 +02:00
Sven Neumann
dd1e858921
app/display: introduce a style for dimming
2010-09-29 20:34:59 +02:00
Sven Neumann
eb5bb6363e
app/display: draw the crop highlight using cairo
...
Instead of dimming the actual pixels, apply a translucent fill to
the area outside the highlight rectangle.
2010-09-29 20:34:59 +02:00
Sven Neumann
ccee0ec41a
app/display: let cairo render the checkerboard
...
Instead of blending the scaled image data onto the checkerboard and
then painting this image to the screen, render the image data into
an ARGB cairo image surface. Then paint a checkerboard on the canvas
and the image on top of it.
2010-09-29 20:34:59 +02:00
Michael Natterer
ebeb933350
app: add gimp_display_shell_expose_item() and use it in the draw tool
2010-09-29 20:10:21 +02:00
Michael Natterer
7367ec1b7c
app: fix the extents of filled rectangles and invalidate less pixels
...
for large unfilled ones: if larger than 64x64 (arbitrary), invalidate
only the actual lines.
2010-09-29 19:58:59 +02:00
Mukund Sivaraman
5dfb2782dd
Use libapp_generated_sources in Makefile.am
2010-09-29 00:39:23 +05:30
Nils Philippsen
6b1aabfa71
add git-version.h to BUILT_SOURCES
...
This is so that it gets built before automake descends into subdirs.
2010-09-28 18:19:34 +02:00