search for: original_extents

Displaying 20 results from an estimated 21 matches for "original_extents".

2007 Oct 18
0
11 commits - libswfdec/swfdec_as_strings.c libswfdec/swfdec_text_field.c libswfdec/swfdec_text_field.h libswfdec/swfdec_text_field_movie_as.c libswfdec/swfdec_text_field_movie.c libswfdec/swfdec_text_field_movie.h test/trace
...changed; g_return_val_if_fail (SWFDEC_IS_TEXT_FIELD_MOVIE (text), FALSE); @@ -811,6 +764,14 @@ swfdec_text_field_movie_auto_size (SwfdecTextFieldMovie *text) swfdec_text_field_movie_free_layouts (layouts); layouts = NULL; + if ((text->text->word_wrap || SWFDEC_MOVIE (text)->original_extents.x1 - + SWFDEC_MOVIE (text)->original_extents.x0 == width) && + (SWFDEC_GRAPHIC (text->text)->extents.y1 - + SWFDEC_GRAPHIC (text->text)->extents.y0 == height)) + return FALSE; + + swfdec_movie_invalidate (SWFDEC_MOVIE (text)); + if (!text->text->word_wr...
2007 Nov 01
0
5 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_object.c libswfdec/swfdec_text_field_movie.c test/image
...airo_rectangle (cr, limit.x0, limit.y0, limit.x1 - limit.x0, limit.y1 - limit.y0); color = swfdec_color_apply_transform (text_movie->background_color, trans); swfdec_color_set_source (cr, color); cairo_fill (cr); } if (text->border) { - cairo_rectangle (cr, movie->original_extents.x0, - movie->original_extents.y0, movie->original_extents.x1, - movie->original_extents.y1); + cairo_rectangle (cr, movie->original_extents.x0 + SWFDEC_DOUBLE_TO_TWIPS (1), + movie->original_extents.y0, movie->original_extents.x1 - + movie->original_extents.x0 - SWFDEC_DOUBL...
2007 Nov 07
0
2 commits - libswfdec/swfdec_resource.c libswfdec/swfdec_text_field_movie.c
...r') { + paragraph->newline = TRUE; + } else { + paragraph->newline = FALSE; + } paragraph->blocks = NULL; paragraph->attrs = NULL; @@ -748,7 +753,8 @@ swfdec_text_field_movie_render (SwfdecMovie *movie, cairo_t *cr, first = TRUE; linenum = 0; - x = movie->original_extents.x0 + EXTRA_MARGIN + text_movie->hscroll; + x = movie->original_extents.x0 + EXTRA_MARGIN + + MIN (text_movie->hscroll, text_movie->hscroll_max); y = movie->original_extents.y0 + EXTRA_MARGIN; for (i = 0; layouts[i].layout != NULL && y < limit.y1; i++) @@ -761,7...
2007 Mar 21
0
4 commits - libswfdec/swfdec_js_movie.c libswfdec/swfdec_script.c player/swfdec_slow_loader.c
...0 }, @@ -970,9 +984,9 @@ mc_width_set (JSContext *cx, JSObject *o } swfdec_movie_update (movie); movie->modified = TRUE; - cur = SWFDEC_TWIPS_TO_DOUBLE ((SwfdecTwips) (rint (movie->extents.x1 - movie->extents.x0))); + cur = SWFDEC_TWIPS_TO_DOUBLE ((SwfdecTwips) (rint (movie->original_extents.x1 - movie->original_extents.x0))); if (cur != 0) { - movie->xscale *= d / cur; + movie->xscale = 100 * d / cur; } else { movie->xscale = 0; movie->yscale = 0; @@ -1016,9 +1030,9 @@ mc_height_set (JSContext *cx, JSObject * } swfdec_movie_update (movie);...
2007 Oct 17
0
libswfdec/swfdec_text_field.c libswfdec/swfdec_text_field.h libswfdec/swfdec_text_field_movie.c
...text_movie = SWFDEC_TEXT_FIELD_MOVIE (movie); + text = SWFDEC_TEXT_FIELD (movie->graphic); + + if (text_movie->paragraphs == NULL) + swfdec_text_field_movie_generate_paragraphs (text_movie); + paragraphs = text_movie->paragraphs; + + swfdec_rect_intersect (&limit, &movie->original_extents, inval); + + cairo_rectangle (cr, limit.x0, limit.y0, limit.x1 - limit.x0, limit.y1 - limit.y0); + cairo_clip (cr); + + if (text->background) { + cairo_rectangle (cr, limit.x0, limit.y0, limit.x1, limit.y1); + color = swfdec_color_apply_transform (text_movie->background_color, trans)...
2007 Nov 01
0
2 commits - libswfdec/swfdec_text_field_movie.c test/image
...kground_color, trans); - swfdec_color_set_source (cr, color); + // always use full alpha + swfdec_color_set_source (cr, (color & 0xffffff) + (255 << 24)); cairo_fill (cr); } @@ -604,7 +605,8 @@ swfdec_text_field_movie_render (SwfdecMovie *movie, cairo_t *cr, movie->original_extents.y1 - movie->original_extents.y0 - SWFDEC_DOUBLE_TO_TWIPS (1)); color = swfdec_color_apply_transform (text_movie->border_color, trans); - swfdec_color_set_source (cr, color); + // always use full alpha + swfdec_color_set_source (cr, (color & 0xffffff) + (255 << 24));...
2007 Nov 04
0
7 commits - libswfdec/swfdec_text_field_movie.c libswfdec/swfdec_text_field_movie.h libswfdec/swfdec_text_field_movie_html.c
..._y = ascent - baseline; layout.height = ascent + descent; } } @@ -719,8 +759,7 @@ swfdec_text_field_movie_render (SwfdecMovie *movie, cairo_t *cr, if (linenum == text_movie->scroll) skipped = rect.y; - if (!first && - y + rect.y + rect.height > movie->original_extents.y1) + if (!first && y + rect.y + rect.height > movie->original_extents.y1) break; first = FALSE; @@ -733,12 +772,16 @@ swfdec_text_field_movie_render (SwfdecMovie *movie, cairo_t *cr, x + layout->offset_x + rect.x + rect.width < limit.x0) continue; +...
2007 Jul 18
0
12 commits - configure.ac doc/swfdec-sections.txt libswfdec-gtk/swfdec_playback_alsa.c libswfdec/jpeg libswfdec/Makefile.am libswfdec/swfdec_amf.c libswfdec/swfdec_as_array.c libswfdec/swfdec_as_boolean.h libswfdec/swfdec_as_context.c
...extents.x0); + d = SWFDEC_TWIPS_TO_DOUBLE ((SwfdecTwips) d); SWFDEC_AS_VALUE_SET_NUMBER (rval, d); } @@ -236,7 +237,8 @@ mc_width_set (SwfdecMovie *movie, const } swfdec_movie_update (movie); movie->modified = TRUE; - cur = SWFDEC_TWIPS_TO_DOUBLE ((SwfdecTwips) (rint (movie->original_extents.x1 - movie->original_extents.x0))); + cur = rint (movie->original_extents.x1 - movie->original_extents.x0); + cur = SWFDEC_TWIPS_TO_DOUBLE ((SwfdecTwips) cur); if (cur != 0) { movie->xscale = 100 * d / cur; } else { @@ -252,7 +254,8 @@ mc_height_get (SwfdecMovie *movie, Swf...
2007 Aug 22
0
8 commits - libswfdec/swfdec_movie.c libswfdec/swfdec_movie.h libswfdec/swfdec_player.c libswfdec/swfdec_player_internal.h libswfdec/swfdec_sprite_movie_as.c vivified/core
...ECT (&argv[0]))) { SWFDEC_ERROR ("FIXME: what happens now?"); @@ -170,70 +169,29 @@ swfdec_sprite_movie_hitTest (SwfdecAsCon } swfdec_movie_update (movie); swfdec_movie_update (other); - if (movie->parent != other->parent) { - movie_rect = movie->original_extents; - other_rect = other->original_extents; - swfdec_movie_update (other); - tmp = movie; - for (movie_depth = 0; tmp->parent; movie_depth++) - tmp = tmp->parent; - tmp = other; - for (other_depth = 0; tmp->parent; other_depth++) - tmp = tmp->parent; -...
2007 Nov 07
0
14 commits - libswfdec/swfdec_as_context.c libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_interpret.h libswfdec/swfdec_net_stream.c libswfdec/swfdec_script.c libswfdec/swfdec_sprite_movie.c libswfdec/swfdec_tag.c libswfdec/swfdec_text_field_movie.c
...tFieldMovie *text, int *num, // set rendering position layout.offset_x = block->left_margin + block->block_indent; if (paragraphs[i].bullet) - layout.offset_x += 36 * 20; + layout.offset_x += SWFDEC_DOUBLE_TO_TWIPS (BULLET_MARGIN); width = SWFDEC_MOVIE (text)->original_extents.x1 - SWFDEC_MOVIE (text)->original_extents.x0 - block->right_margin - @@ -569,9 +570,10 @@ swfdec_text_field_movie_get_layouts (SwfdecTextFieldMovie *text, int *num, // set paragraph styles if (block->index_ == 0) { pango_layout_set_indent (playout, paragraphs[i].indent);...
2007 Mar 02
0
12 commits - libswfdec/Makefile.am libswfdec/swfdec_audio_flv.c libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_js.c libswfdec/swfdec_js.h libswfdec/swfdec_js_video.c libswfdec/swfdec_loader.c libswfdec/swfdec_loader_internal.h
...100644 --- a/libswfdec/swfdec_video_movie.c +++ b/libswfdec/swfdec_video_movie.c @@ -46,7 +46,9 @@ swfdec_video_movie_render (SwfdecMovie * if (movie->image == NULL) return; - cairo_scale (cr, SWFDEC_TWIPS_SCALE_FACTOR, SWFDEC_TWIPS_SCALE_FACTOR); + cairo_scale (cr, + (mov->original_extents.x1 - mov->original_extents.x0) / movie->image_width, + (mov->original_extents.y1 - mov->original_extents.y0) / movie->image_height); cairo_set_source_surface (cr, movie->image, 0.0, 0.0); cairo_paint (cr); } @@ -140,15 +142,20 @@ swfdec_video_movie_clear (SwfdecVideoMo...
2007 Aug 17
0
3 commits - libswfdec/swfdec_sprite_movie_as.c test/trace
...ue_to_number (cx, &argv[1]); + + if (argc >= 3) { + if (swfdec_as_value_to_boolean (cx, &argv[2])) { + SWFDEC_FIXME ("hitTest's shapeFlag parameter not supported"); + // just continue... + } + } + + swfdec_movie_update (movie); + movie_rect = movie->original_extents; + while (movie->parent) { + swfdec_rect_transform (&movie_rect, &movie_rect, &movie->matrix); + movie = movie->parent; + } + + SWFDEC_AS_VALUE_SET_BOOLEAN (rval, swfdec_rect_contains (&movie_rect, + SWFDEC_PLAYER (cx)->mouse_x, SWFDEC_PLAYER (cx)-&g...
2007 Oct 18
0
18 commits - doc/swfdec-sections.txt libswfdec/Makefile.am libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_strings.c libswfdec/swfdec_button_movie.c libswfdec/swfdec_event.c libswfdec/swfdec_event.h libswfdec/swfdec_flash_security.c
..._movie_render (SwfdecMovie *mov, cairo_t *cr, const SwfdecColorTransform *trans, const SwfdecRect *inval) { SwfdecVideoMovie *movie = SWFDEC_VIDEO_MOVIE (mov); + swfdec_video_movie_update_image (movie); if (movie->image == NULL) return; cairo_scale (cr, - (mov->original_extents.x1 - mov->original_extents.x0) / movie->image_width, - (mov->original_extents.y1 - mov->original_extents.y0) / movie->image_height); + (mov->original_extents.x1 - mov->original_extents.x0) + / cairo_image_surface_get_width (movie->image), + (mov->origi...
2007 Apr 16
0
7 commits - libswfdec/swfdec_codec_gst.c libswfdec/swfdec_font.c libswfdec/swfdec_js_movie.c libswfdec/swfdec_morph_movie.c libswfdec/swfdec_pattern.c libswfdec/swfdec_pattern.h libswfdec/swfdec_shape.c libswfdec/swfdec_shape.h libswfdec/swfdec_sprite.c
...} other = SWFDEC_MOVIE (JS_GetPrivate(cx, JSVAL_TO_OBJECT (argv[0]))); swfdec_movie_update (movie); - swfdec_movie_update (other); - /* FIXME */ - g_assert (movie->parent == other->parent); + if (movie->parent != other->parent) { + movie_rect = movie->original_extents; + other_rect = other->original_extents; + swfdec_movie_update (other); + tmp = movie; + for (movie_depth = 0; tmp->parent; movie_depth++) + tmp = tmp->parent; + tmp = other; + for (other_depth = 0; tmp->parent; other_depth++) + tmp = tmp->parent; +...
2007 Oct 23
0
9 commits - libswfdec/swfdec_as_strings.c libswfdec/swfdec_html_parser.c libswfdec/swfdec_style_sheet.c libswfdec/swfdec_style_sheet.h libswfdec/swfdec_text_field_movie_as.c libswfdec/swfdec_text_field_movie.c libswfdec/swfdec_text_field_movie.h
...diff --git a/libswfdec/swfdec_text_field_movie.c b/libswfdec/swfdec_text_field_movie.c index c071666..b56466d 100644 --- a/libswfdec/swfdec_text_field_movie.c +++ b/libswfdec/swfdec_text_field_movie.c @@ -611,7 +611,7 @@ swfdec_text_field_movie_render (SwfdecMovie *movie, cairo_t *cr, movie->original_extents.y1); color = swfdec_color_apply_transform (text_movie->border_color, trans); swfdec_color_set_source (cr, color); - cairo_set_line_width (cr, 20.0); // FIXME: Is this correct? + cairo_set_line_width (cr, SWFDEC_DOUBLE_TO_TWIPS (1)); cairo_stroke (cr); } commit c7c15478f...
2007 Oct 29
0
20 commits - libswfdec/Makefile.am libswfdec/swfdec_as_interpret.c libswfdec/swfdec_html_parser.c libswfdec/swfdec_initialize.as libswfdec/swfdec_initialize.h libswfdec/swfdec_text_field.c libswfdec/swfdec_text_field.h
...xt_field_movie, SWFDEC_TYPE_MOVIE) +#define EXTRA_MARGIN 2 + static void swfdec_text_field_movie_update_extents (SwfdecMovie *movie, SwfdecRect *extents) @@ -611,8 +613,8 @@ swfdec_text_field_movie_render (SwfdecMovie *movie, cairo_t *cr, first = TRUE; linenum = 0; - x = movie->original_extents.x0 + text_movie->hscroll; - y = movie->original_extents.y0 + 1; + x = movie->original_extents.x0 + EXTRA_MARGIN + text_movie->hscroll; + y = movie->original_extents.y0 + EXTRA_MARGIN; cairo_move_to (cr, x, y); for (i = 0; layouts[i].layout != NULL/* && y < limit...
2007 Dec 10
0
6 commits - libswfdec/Makefile.am libswfdec/swfdec_as_interpret.c libswfdec/swfdec_color_as.c libswfdec/swfdec_graphic_movie.c libswfdec/swfdec_image_decoder.c libswfdec/swfdec_morph_movie.c libswfdec/swfdec_movie_as_drawing.c
...XTENTS); } static void @@ -87,6 +89,15 @@ swfdec_morph_movie_render (SwfdecMovie *movie, cairo_t *cr, } static void +swfdec_morph_movie_invalidate (SwfdecMovie *movie, const cairo_matrix_t *matrix, gboolean last) +{ + SwfdecRect rect; + + swfdec_rect_transform (&rect, &movie->original_extents, matrix); + swfdec_player_invalidate (SWFDEC_PLAYER (SWFDEC_AS_OBJECT (movie)->context), &rect); +} + +static void swfdec_morph_movie_dispose (GObject *object) { SwfdecMorphMovie *morph = SWFDEC_MORPH_MOVIE (object); @@ -109,6 +120,7 @@ swfdec_morph_movie_class_init (SwfdecMorphMovieCl...
2007 Nov 15
2
Changes to 'refs/tags/0.5.4'
Tag '0.5.4' created by Benjamin Otte <otte at gnome.org> at 2007-11-15 10:12 -0800 release 0.5.4 ("Turkish Cycling Federation") -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) iD8DBQBHPBurvMv5VCdLq8QRAj1KAJ40NHRRS3gKyJjSjyyoH7gDaGi/tQCeOha/ R5PF4bZQqmSdJ64t8EbD4cA= =8qBy -----END PGP SIGNATURE----- Changes since the dawn of time: Benjamin Otte (40):
2007 Oct 18
0
14 commits - libswfdec/swfdec_as_strings.c libswfdec/swfdec_initialize.as libswfdec/swfdec_initialize.h libswfdec/swfdec_text_field_movie_as.c libswfdec/swfdec_text_field_movie.c libswfdec/swfdec_text_field_movie.h libswfdec/swfdec_text_format.c
...ght, width, diff; + + g_return_val_if_fail (SWFDEC_IS_TEXT_FIELD_MOVIE (text), FALSE); + + if (text->text->auto_size == SWFDEC_AUTO_SIZE_NONE) + return FALSE; + + swfdec_text_field_get_size (text, &width, &height); if ((text->text->word_wrap || SWFDEC_MOVIE (text)->original_extents.x1 - SWFDEC_MOVIE (text)->original_extents.x0 == width) && diff --git a/libswfdec/swfdec_text_field_movie.h b/libswfdec/swfdec_text_field_movie.h index f5b26d3..c1eed50 100644 --- a/libswfdec/swfdec_text_field_movie.h +++ b/libswfdec/swfdec_text_field_movie.h @@ -119,6 +119,9 @@ G...
2007 Aug 20
0
Branch 'vivi' - 60 commits - libswfdec-gtk/swfdec_gtk_loader.c libswfdec/Makefile.am libswfdec/swfdec_as_array.c libswfdec/swfdec_as_context.c libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame_internal.h libswfdec/swfdec_as_interpret.c
...ue_to_number (cx, &argv[1]); + + if (argc >= 3) { + if (swfdec_as_value_to_boolean (cx, &argv[2])) { + SWFDEC_FIXME ("hitTest's shapeFlag parameter not supported"); + // just continue... + } + } + + swfdec_movie_update (movie); + movie_rect = movie->original_extents; + while (movie->parent) { + swfdec_rect_transform (&movie_rect, &movie_rect, &movie->matrix); + movie = movie->parent; + } + + SWFDEC_AS_VALUE_SET_BOOLEAN (rval, swfdec_rect_contains (&movie_rect, + SWFDEC_PLAYER (cx)->mouse_x, SWFDEC_PLAYER (cx)-&g...