--- image.module	2008-09-02 17:41:56.000000000 +0100
+++ image.module.new	2008-09-06 06:22:35.468513400 +0100
@@ -655,14 +655,14 @@ function image_fetch($nid = 0, $size = I
  * Theme a teaser
  */
 function theme_image_teaser($node, $size) {
-  return l(image_display($node, IMAGE_THUMBNAIL), 'node/'. $node->nid, array('html' => TRUE));
+  return l(image_display($node, variable_get('image_size_teaser_image', IMAGE_THUMBNAIL)), 'node/'. $node->nid, array('html' => TRUE));
 }
 
 /**
  * Theme a body
  */
 function theme_image_body($node, $size) {
-  return image_display($node, $size);
+  return image_display($node, variable_get('image_size_body_image', $size));
 }
 
 /**
@@ -1033,3 +1033,37 @@ function image_create_node_from($filepat
   return $node;
 }
 
+/**
+ * implementation of hook_form_alter()
+ */
+function image_form_alter(&$form, $form_state, $form_id) {
+  // Content type settings form.
+  if ($form_id == 'node_type_form' && $form['#node_type']->type == 'image') {
+    _image_check_settings();
+
+    foreach (image_get_sizes() as $key => $size) {
+      $image_sizes[$key] = $size['label'];
+    }
+    
+    $form['image_size'] = array(
+      '#type' => 'fieldset',
+      '#title' => t('Image size settings'),
+      '#collapsible' => TRUE,
+      '#collapsed' => TRUE,
+    );
+    $form['image_size']['image_size_teaser'] = array(
+      '#type' => 'select',
+      '#title' => t('Teaser image size'),
+      '#default_value' => variable_get('image_size_teaser_image', IMAGE_THUMBNAIL),
+      '#options' => $image_sizes,
+      '#description' => t("This determines the size of the image that appears when the node is displayed as a teaser. 'Hidden' will not show the image.")
+    );
+    $form['image_size']['image_size_body'] = array(
+      '#type' => 'select',
+      '#title' => t('Full node image size'),
+      '#default_value' => variable_get('image_size_body_image', IMAGE_PREVIEW),
+      '#options' => $image_sizes,
+      '#description' => t("This determines the size of the image that appears when the full node is displayed. 'Hidden' will not show the image.")
+    );
+  }
+}
\ No newline at end of file
