diff options
| author | Jabier Arraiza <jabier.arraiza@marker.es> | 2019-10-21 00:15:00 +0000 |
|---|---|---|
| committer | Jabier Arraiza <jabier.arraiza@marker.es> | 2019-10-21 00:15:00 +0000 |
| commit | 966430dfc94b1552d3dbf6168caeddcf30d0f21c (patch) | |
| tree | dd7a00969acfa3e6c0aab2581f89fa9d8bc2e319 | |
| parent | CI: Store artifacts for test job (diff) | |
| download | inkscape-966430dfc94b1552d3dbf6168caeddcf30d0f21c.tar.gz inkscape-966430dfc94b1552d3dbf6168caeddcf30d0f21c.zip | |
Remove isolate check. Need to find a way to isolate all containers
| -rw-r--r-- | src/display/drawing-item.cpp | 18 | ||||
| -rw-r--r-- | src/ui/widget/filter-effect-chooser.cpp | 12 |
2 files changed, 23 insertions, 7 deletions
diff --git a/src/display/drawing-item.cpp b/src/display/drawing-item.cpp index 3a4f5cfc2..fdc619bd4 100644 --- a/src/display/drawing-item.cpp +++ b/src/display/drawing-item.cpp @@ -674,13 +674,14 @@ DrawingItem::render(DrawingContext &dc, Geom::IntRect const &area, unsigned flag return RENDER_OK; } + setCached(true, true); + // carea is the area to paint Geom::OptIntRect carea = Geom::intersect(area, _drawbox); // expand render on filtered items Geom::OptIntRect cl = _cacheRect(); if (_filter != nullptr && render_filters && cl) { - setCached(true, true); carea = cl; } @@ -741,7 +742,7 @@ DrawingItem::render(DrawingContext &dc, Geom::IntRect const &area, unsigned flag nir |= (_mask != nullptr); // 2. it has a mask nir |= (_filter != nullptr && render_filters); // 3. it has a filter nir |= needs_opacity; // 4. it is non-opaque - nir |= (_cache != nullptr); // 5. it is to be cached + /* How the rendering is done. * * Clipping, masking and opacity are done by rendering them to a surface @@ -752,6 +753,15 @@ DrawingItem::render(DrawingContext &dc, Geom::IntRect const &area, unsigned flag * value corresponding to the opacity. If there is no clipping path, * the entire intermediate surface is painted with alpha corresponding * to the opacity value. + * + * Blending, isolation and _cache nir check are removed because: + * Blending: is handled in the shortcircuit + * Isolation: Is handles in drawing-group + * _cache: if nir is false, we realy dont want a cache element, never do it + * previously on bug exception when previous state of nir is true that cause + * inconguences with cache noticiable changing zoom, removing _cache from nir + * and deleting it inside the shortcicuit seems the correct way to do + * */ // Short-circuit the simple case. // We also use this path for filter background rendering, because masking, clipping, @@ -759,9 +769,7 @@ DrawingItem::render(DrawingContext &dc, Geom::IntRect const &area, unsigned flag // element if ((flags & RENDER_FILTER_BACKGROUND) || !needs_intermediate_rendering) { - if (_cache) { - _cache->markDirty(*carea); - } + setCached(false, true); dc.setOperator(ink_css_blend_to_cairo_operator(_mix_blend_mode)); return _renderItem(dc, *carea, flags & ~RENDER_FILTER_BACKGROUND, stop_at); } diff --git a/src/ui/widget/filter-effect-chooser.cpp b/src/ui/widget/filter-effect-chooser.cpp index fc5adbb59..d0442bddd 100644 --- a/src/ui/widget/filter-effect-chooser.cpp +++ b/src/ui/widget/filter-effect-chooser.cpp @@ -74,13 +74,21 @@ SimpleFilterModifier::SimpleFilterModifier(int flags) _lb_blend.set_mnemonic_widget(_blend); _hb_blend.pack_start(_lb_blend, false, false, 5); _hb_blend.pack_start(_blend, false, false, 5); - if (flags & ISOLATION) { + /* + * For best fit inkscape-browsers with no GUI to isolation we need all groups, + * clones and symbols with isolation == isolate to not show to the user of + * Inkscape a "strange" behabiour from the designer point of view. + * Is strange because only happends when object not has clip, mask, + * filter, blending or opacity . + * Anyway the feature is a no-gui feature and render as spected. + /* + /* if (flags & ISOLATION) { _isolation.property_active() = false; _hb_blend.pack_start(_isolation, false, false, 5); _hb_blend.pack_start(_lb_isolation, false, false, 5); _isolation.set_tooltip_text("Don't blend childrens with objects behind"); _lb_isolation.set_tooltip_text("Don't blend childrens with objects behind"); - } + } */ _hb_blend.pack_start(_lb_blend, false, false, 5); _hb_blend.pack_start(_blend, false, false, 5); Gtk::Separator *separator = Gtk::manage(new Gtk::Separator()); |
