Index: themes/xtemplate/xtemplate.css
===================================================================
RCS file: /cvs/drupal/drupal/themes/xtemplate/xtemplate.css,v
retrieving revision 1.52
diff -u -r1.52 xtemplate.css
--- themes/xtemplate/xtemplate.css	9 Feb 2004 06:11:55 -0000	1.52
+++ themes/xtemplate/xtemplate.css	11 Feb 2004 05:37:01 -0000
@@ -219,6 +219,10 @@
   font-size: 0.8em;
   padding: 1.5em;
 }
+.node .avatar {
+  float: left;
+  padding: 0.5em;
+}
 .comment {
   border: 1px solid #abc;
   padding: .5em;
@@ -234,6 +238,10 @@
   float: right;
   color: red;
 }
+.comment .avatar {
+  float: left;
+  padding: 0.5em;
+}
 
 /*
 ** Module specific styles
Index: themes/xtemplate/xtemplate.theme
===================================================================
RCS file: /cvs/drupal/drupal/themes/xtemplate/xtemplate.theme,v
retrieving revision 1.50
diff -u -r1.50 xtemplate.theme
--- themes/xtemplate/xtemplate.theme	1 Feb 2004 21:37:50 -0000	1.50
+++ themes/xtemplate/xtemplate.theme	11 Feb 2004 05:37:01 -0000
@@ -15,6 +15,7 @@
   $output .= form_textarea(t("Primary links"), "xtemplate_primary_links", variable_get("xtemplate_primary_links", l("edit primary links", "admin/system/themes/xtemplate")), 70, 8, t("The HTML code for the primary links."));
   $output .= form_textarea(t("Secondary links"), "xtemplate_secondary_links", variable_get("xtemplate_secondary_links", l("edit secondary links", "admin/system/themes/xtemplate")), 70, 8, t("The HTML code for the secondary links."));
   $output .= form_radios(t("Search box"), "xtemplate_search_box", variable_get("xtemplate_search_box", 0), array(t("Disabled"), t("Enabled")), t("Show a search box in the upper right corner."));
+  $output .= form_group(t("Avatars"), form_checkbox(t("Display avatars with nodes"), "xtemplate_avatar_node", 1, variable_get("xtemplate_avatar_node", 0), t("Display individualized pictures identifying users with posts they start.")) . form_checkbox(t("Display avatars with comments"), "xtemplate_avatar_comment", 1, variable_get("xtemplate_avatar_comment", 0), t("Display individualized pictures identifying users with their comments.")) . form_textfield(t("Default avatar"), "xtemplate_avatar_default", variable_get("xtemplate_avatar_default", ""), 70, 300, t("URL of avatar to display for users with no custom avatar selected. Leave blank for none.")));
   return $output;
 }
 
@@ -49,6 +50,20 @@
     $xtemplate->template->parse("node.title");
   }
 
+  if (module_exist("profile") && variable_get("xtemplate_avatar_node", 0)) {
+    $avatar = $node->profile_avatar;
+    if (empty($avatar) || !file_exists($avatar)) {
+      $avatar = variable_get("xtemplate_avatar_default", "");
+    }
+    else {
+      $avatar = file_create_url($avatar);
+    }
+    if ($avatar) {
+      $xtemplate->template->assign("avatar", "<img src=\"$avatar\" alt=\"" . t("%user's avatar", array("%user" => $comment->name ? $comment->name : t(variable_get("anonymous", "Anonymous")))) . "\" />");
+      $xtemplate->template->parse("node.avatar");
+    }
+  }
+
   if (module_exist("taxonomy") && ($taxonomy = taxonomy_link("taxonomy terms", $node))) {
     $xtemplate->template->assign("taxonomy", theme_links($taxonomy));
     $xtemplate->template->parse("node.taxonomy");
@@ -82,10 +97,26 @@
   if ($comment->new) {
     $xtemplate->template->parse("comment.new");
   }
+  
+  if (module_exist("profile") && variable_get("xtemplate_avatar_comment", 0)) {
+    $avatar = $comment->profile_avatar;
+    if (empty($avatar) || !file_exists($avatar)) {
+      $avatar = variable_get("xtemplate_avatar_default", "");
+    }
+    else {
+      $avatar = file_create_url($avatar);
+    }
+    if ($avatar) {
+      $xtemplate->template->assign("avatar", "<img src=\"$avatar\" alt=\"" . t("%user's avatar", array("%user" => $comment->name ? $comment->name : t(variable_get("anonymous", "Anonymous")))) . "\" />");
+      $xtemplate->template->parse("comment.avatar");
+    }
+  }
+
   if ($links) {
     $xtemplate->template->assign("links", $links);
     $xtemplate->template->parse("comment.links");
   }
+
   $xtemplate->template->parse("comment");
   $output = $xtemplate->template->text("comment");
   $xtemplate->template->reset("comment");
Index: themes/xtemplate/xtemplate.xtmpl
===================================================================
RCS file: /cvs/drupal/drupal/themes/xtemplate/xtemplate.xtmpl,v
retrieving revision 1.34
diff -u -r1.34 xtemplate.xtmpl
--- themes/xtemplate/xtemplate.xtmpl	1 Feb 2004 21:37:50 -0000	1.34
+++ themes/xtemplate/xtemplate.xtmpl	11 Feb 2004 05:37:02 -0000
@@ -56,6 +56,9 @@
 
 <!-- BEGIN: node -->
   <div class="node {static}">
+    <!-- BEGIN: avatar -->
+    <div class="avatar">{avatar}</div>
+    <!-- END: avatar -->
     <!-- BEGIN: title -->
     <h2 class="title"><a href="{link}">{title}</a></h2>
     <!-- END: title -->
@@ -72,6 +75,9 @@
 
 <!-- BEGIN: comment -->
   <div class="comment">
+    <!-- BEGIN: avatar -->
+    <div class="avatar">{avatar}</div>
+    <!-- END: avatar -->
     <h3 class="title">{title}</h3><!-- BEGIN: new --><span class="new">{new}</span><!-- END: new -->
     <div class="submitted">{submitted}</div>
     <div class="content">{content}</div>
