Make image resampling optional in nsgtk

svn path=/trunk/netsurf/; revision=2794
This commit is contained in:
Rob Kendrick 2006-07-23 22:44:42 +00:00
parent 18d84f0c10
commit 000f7502ba
3 changed files with 3 additions and 2 deletions

View File

@ -143,6 +143,7 @@ void nsgtk_options_save(void) {
GET_ENTRY(entryHomePageURL, option_homepage_url);
GET_CHECK(checkUseCairo, option_render_cairo);
GET_CHECK(checkResampleImages, option_render_resample);
/* TODO: save the other options */
options_write(options_file_location);

View File

@ -280,7 +280,8 @@ bool nsgtk_plot_bitmap(int x, int y, int width, int height,
GdkPixbuf *scaled;
scaled = gdk_pixbuf_scale_simple(pixbuf,
width, height,
GDK_INTERP_BILINEAR);
option_render_resample ? GDK_INTERP_BILINEAR
: GDK_INTERP_NEAREST);
if (!scaled)
return false;

View File

@ -1255,7 +1255,6 @@ NTML authentication</property>
<child>
<widget class="GtkCheckButton" id="checkResampleImages">
<property name="visible">True</property>
<property name="sensitive">False</property>
<property name="tooltip" translatable="yes">Smoothly resize images when zooming in and out.</property>
<property name="can_focus">True</property>
<property name="label" translatable="yes">Resample images when not at natural size</property>