[theme] - [opal] - [halffling's code - k1ified]

Dec 20, 2005 15:39

it ain't perfect. but hot damn it's a lot better.

layerinfo "type" = "theme";
layerinfo "name" = "Default Template (k1)";
layerinfo author_name = "Halffling on LiveJournal.com/Kunzite1 on LiveJournal.com";
layerinfo author_email = "halffling@livejournal.com";
layerinfo des = "Based on the template offered by ignited, cleaned by kunzite1";
layerinfo lang = "en";
layerinfo source_viewable = 1;

set color_bg = "#ffffff";
set color_bg_font = "#737373";
set color_fg = "#dadada";
set color_fg_font = "#818181";
set color_med = "#dadada";
set color_med_font = "#818181";
set font_base = "Trebuchet MS";
set lang_fmt_date_short = "%%day%%, %%month%% %%dayord%% %%yyyy%%";
set lang_fmt_time_short = "%%h%%:%%min%%%%a%%m";
set links_header = "Links";
set show_entry_userpic = true;
set static_font_size = "11";
set static_font_measurement = "px";
set tags_aware = true;
set text_back = "Back";
set text_forward = "Forward";
set text_meta_location = "Location:";
set text_meta_mood = "Mood:";
set text_meta_music = "Music:";
set text_post_comment = "Comment";
set text_post_comment_friends = "Comment";
set text_read_comments = "1 comment // # comments";
set text_read_comments_friends = "1 // #";

function Page::print_custom_head() {
"""

""";
}

function print_stylesheet() {
var string page_background_image = "";
var Color color_one = "#e6e6e6";
var Color color_two = "#c1c1c1";
var Color color_three = "#cdcdcd";
var Color color_four = "#b4b4b4";
var Color color_five = "#9a9a9a";
var Color color_six = "#4b4b4b";
var Color color_seven = "#595959";
var Color color_eight = "#000000";
var Color color_nine = "#3d3d3d";
var Color color_ten = "#d0d0d0";
var Color color_eleven = "#447369";
var Color color_twelve = "#a7a7a7";

var string static_font_size_plus1 = (int($*static_font_size) + 1) + "";
var string static_font_size_minus1 = (int($*static_font_size) - 1) + "";
var string static_font_size_minus2 = (int($*static_font_size) - 2) + "";

"""
/* Hello! This is the stylesheet of Halffling @ LJ. */
/* My comments are placed between things like this */
/* in order to help you along. */

body {
background-color: $*color_bg;
""";
if(clean_url($page_background_image) != "") {
$page_background_image = clean_url($page_background_image);
"""
background-image: url($page_background_image);
""";
}
"""
font-family: $*font_base;
color: $*color_bg_font;
font-size: $*static_font_size$*static_font_measurement;
line-height: 9pt;
overflow-x: hidden;
margin: 5px;
margin-top: 10px;
}

html {
scrollbar-face-color: $*color_fg;
scrollbar-arrow-color: $*color_fg;
scrollbar-highlight-color: $color_one;
scrollbar-3dlight-color: $color_two;
scrollbar-shadow-color: $color_three;
scrollbar-darkshadow-color: $color_two;
scrollbar-track-color: $*color_bg;
}

.pagealign {
text-align: center;
}

.bodytable {
width: 50%;
}

/* borders along the page. */
/* To disable a border, change to 0px */
.border4 {
border: 1px solid $color_four;
}

.border3 {
border: 2px solid $color_three;
}

.border2 {
border: 1px solid $color_five;
}

/* links on page */
a, a b {
color: $color_six;
font-weight: bold;
text-decoration: none;
}

/* links when cursor is hovering over it */
a:hover, a:hover b, a:hover .nosubject {
color: $*color_bg_font;
font-weight: bold;
text-decoration: none;
}

/* italicized text. Remove if you don't want it a different color */
i {
color: $color_seven;
}

/* bolded text. Remove if you don't want it a different color */
b {
color: $color_seven;
}

/* change to 'float:right' if you want your posting icon on the right. */
.userpic2 {
float: left;
text-align: right;
margin-top: 0px;
margin-right: 0px;
}

/*if userpic in the sidebar is enabled. */
#userpic {
overflow: visible;
text-align: center;
margin-bottom: 5px;
padding: 2px;
}

/* the next three deal with the navigation links at the top */
#nav {
background-color: $color_four;
font-size: $static_font_size_minus1$*static_font_measurement;
letter-spacing: 2px;
text-transform: uppercase;
padding-top: 10px;
white-space: nowrap;
}

#nav a {
font-size: $static_font_size_minus1$*static_font_measurement;
color: $color_one;
text-decoration: none;
padding-left: 12px;
padding-right: 10px;
padding-top: 1px;
background-color: $color_four;
}

#nav a:hover {
color: $*color_bg_font;
background-color: $color_three;
}

/* main area of text */
#content {
background-color: $*color_fg;
padding: 2px;
}

.sidetd {
width: 175px;
}

/* the columns */
.columncontent {
font-size: $*static_font_size$*static_font_measurement;
text-align: center;
background-color: $color_one;
padding: 2px;
}

/* the header of each column */
.columncontent strong {
font-size: $static_font_size_minus1$*static_font_measurement;
color: $*color_bg_font;
font-weight: bold;
text-transform: uppercase;
}

/* text area of the columns */
.columnitem {
padding: 2px;
margin-top: 4px;
background-color: $*color_bg;
border: 1px solid $color_five;
overflow: visible;
}

/* links in the side column */
#sidecolumn a {
color: $color_five;
font-size: $static_font_size_minus1$*static_font_measurement;
text-decoration: none;
}

#sidecolumn a:hover {
color: $color_eight;
font-size: $static_font_size_minus1$*static_font_measurement;
text-decoration: none;
}

/* the calendar on the side */
.calrow {
clear: both;
width: 120px;
text-align: center;
}

.calempty {
width: 5px;
}

.calactitem {
font-size: $static_font_size_minus2$*static_font_measurement;
text-align: center;
background-color: $color_three;
}

.calinitem {
font-size: $static_font_size_minus2$*static_font_measurement;
text-align: center;
}

/* days on the calendar page */
.bigday {
font-size: $*static_font_size$*static_font_measurement;
font-weight: bold;
}

/* the text area on the Reply to Post or Comment page */
input, textarea, select {
color: $*color_fg_font;
font-family: $*font_base;
font-size: $*static_font_size$*static_font_measurement;
background-color: $*color_fg;
border: 1px solid $color_two;
}

/* the subject of the post */
.subject {
color: $color_nine;
font-size: $static_font_size_plus1$*static_font_measurement;
font-weight: bold;
text-transform: uppercase;
padding-top: 1px;
padding-bottom: 1px;
}

/* the following deal with entries themselves */
.entry {
font-size: $*static_font_size$*static_font_measurement;
margin-bottom: 10px;
}

/* the following was causing issues in firefox */
/*
.entrytext {
overflow-x: hidden;
text-overflow: clip;
word-wrap: break-word;
}
*/

.entrycontent {
width: 50%;
}

/* mood & song */
.meta {
text-transform: uppercase;
font-size: $static_font_size_minus1$*static_font_measurement;
font-weight: bold;
}

/* tags */
.tags {
color: $color_five;
font-size: $static_font_size_minus2$*static_font_measurement;
background-color: $color_ten;
text-transform: uppercase;
padding: 1px;
}

/* the next two are where it says "posted by" */
.entryinfo {
color: $color_five;
font-size: $static_font_size_minus1$*static_font_measurement;
font-weight: bold;
text-transform: uppercase;
background-color: $color_one;
padding-top: 2px;
padding-bottom: 2px;
}

/* the next three deal with the links at the bottom of each entry */
.entrylinks {
font-size: $static_font_size_minus2$*static_font_measurement;
padding-top: 2px;
padding-bottom: 2px;
background-color: $color_two;
text-align: center;
}

.entrylinks a {
color: $color_six;
text-align: center;
text-transform: uppercase;
text-decoration: none;
white-space: nowrap;
}

.entrylinks a:hover {
color: $color_eight;
background-color: $color_four;
text-decoration: none;
}

/* when a whole bunch of replies occurs and they turn to boxes */
.minicomment {
font-size: $*static_font_size$*static_font_measurement;
padding: 4px;
background-color: $color_one;
border: 2px solid $*color_bg;
}

.minicommentholder {
border: 1px solid $color_two;
}

.messageholder {
border: 1px solid $color_two;
margin-bottom: 5px;
margin-top: 5px;
}

/* when viewing comments, where it says "comments" */
.notablemessage {
padding: 4px;
}

/* year in calendar page */
.systemtext {
color: $color_eleven;
font-weight: bold;
text-transform: uppercase;
}

/* back, forward links, etc. */
.systemmessage {
font-size: $*static_font_size$*static_font_measurement;
background-color: $color_one;
border: 2px solid $*color_bg;
}

.systemmessage a {
padding-left: 10px;
padding-right: 10px;
padding-top: 2px;
padding-bottom: 2px;
}

.systemmessage TD {
font-size: $*static_font_size$*static_font_measurement;
padding: 2px;
}

/* on the comments page, the username of the commenter */
.postedby {
font-size: $*static_font_size$*static_font_measurement;
text-transform: uppercase;
}

/* if you enabled IP logging */
.ip {
color: $color_eleven;
}

/* if logged in, this edits the "mass action on selected comments" option */
.multiform {
font-weight: bold;
}

/* the links that say 'back to top' at the bottom of each entry */
.backtop {
text-align: right;
}

.backtop a {
color: $color_twelve;
}

/* I'm not sure if the next two really do anything */
.friendcolor {
width: 10px;
height: 10px;
}

.friendname {
text-decoration: none;
}
""";
}

function Entry::print_metadata() {
var string currents_open = ""; # html for opening of currents container
var string currents_close = ""; # html for closing of currents container

var bool loc_after_mood = false; # set to true to print location after mood
var bool vanilla_loc = false; # set to true to delinkify location

var string meta_label_open = """
"""; # html for opening of metadata label

var string meta_label_close = """ """; # html for closing of metadata label
var string meta_val_open = ""; # html for opening of metadata value
var string meta_val_close = """"""; # html for closing of metadata value

if (size $.metadata > 0){
if($.metadata{"mood"} == "" and $loc_after_mood) {
# if we're printing loc after mood but we have no mood, set loc_after_mood to false
$loc_after_mood = false;
}
var string currents = ""; # make var for printing

$currents = $currents_open; # add opening of currents container

foreach var string k ($.metadata){ # step thru metadata
var string text = $k; # set text to key
var string val = $.metadata{$k}; # get val

if ($k == "mood"){ # if mood, set text to mood property
$text = $*text_meta_mood;
if (defined $.mood_icon){ # if we have a mood icon, add it
var Image i = $.mood_icon;
$val = """
$val""";
}
}
elseif ($k == "music") { # if music, set text to music property
$text = $*text_meta_music;
} elseif ($k == "location") { # if location, set text to loc variable

$text = $*text_meta_location;
if($vanilla_loc) { # if vanilla loc, striphtml() it
$val = striphtml($val);
}
}
if(not ($k == "location" and $loc_after_mood)) {
# if we're doing loc right now and printing loc after mood, skip it
# if we're doing loc right now and we're not printing loc after mood, print it now
# if we're not doing loc right now, print this piece of meta

# add the meta
$currents = $currents + """$meta_label_open$text$meta_label_close$meta_val_open$val$meta_val_close""";
}

if($k == "mood" and $loc_after_mood) {
# if we just now did the mood and we're printing loc after mood, print the loc
$k = "location"; # set meta key to "location"
$text = $*text_meta_location; # set text to loc variable
$val = $.metadata{$k}; # get val

# if we have a loc, do stuff
if($val != "") {

# if vanilla loc, striphtml() it
if($vanilla_loc) {
$val = striphtml($val);
}

# add the meta
$currents = $currents + """$meta_label_open$text$meta_label_close$meta_val_open$val$meta_val_close""";
}
}
}

# close currents container

$currents = $currents + $currents_close;

# print currents
println "$currents";
}
}

function Entry::print_linkbar() {
var string link_seperator = ""; # seperator for links

# initialize array/hashes
var string[] link_keyseq = [""];
var string{} link_url = {"" => ""};
var string{} link_caption = {"" => ""};
var string{} link_image = {"" => ""};

var string print = ""; # var for printing
var Page p = get_page(); # page handle to determine interentry
var bool show_interentry = ($p.view == "entry" or $p.view == "reply"); # if entry/reply view, show interentry
var int keyseq_index = 0; # set index point for new link_keyseq array

if($show_interentry) {
# if show interentry, put previous entry link first
# $link_keyseq[$keyseq_index++] = "nav_prev";

# get previous entry link information
var Link prev = $this->get_link("nav_prev");
$link_url{"nav_prev"} = $prev.url;
$link_caption{"nav_prev"} = $prev.caption;
$link_image{"nav_prev"} = $prev.icon.url;

# get next entry link information
var Link next = $this->get_link("nav_next");
$link_url{"nav_next"} = $next.url;
$link_caption{"nav_next"} = $next.caption;
$link_image{"nav_next"} = $next.icon.url;
}

# gather current linkbar
foreach var string link_key ($.link_keyseq) {
var Link link = $this->get_link($link_key);
$link_url{$link_key} = $link.url;
$link_caption{$link_key} = $link.caption;
$link_image{$link_key} = $link.icon.url;
$link_keyseq[$keyseq_index++] = $link_key; # add this to new link_keyseq array
}
if($show_interentry) {
# if show interentry, put next entry link last
# $link_keyseq[$keyseq_index++] = "nav_next";
}

#################################################################################################################
# by now, the above hashes should look something like: #
# #
# If interentry: #
# Previous Entry: #
# $link_url{"nav_prev"} = http://www.livejournal.com/go.bml?journal=exampleusername&itemid=256&dir=prev #
# $link_caption{"nav_prev"} = Previous Entry #
# $link_image{"nav_prev"} = http://stat.livejournal.com/img/btn_prev.gif #
# #
# Edit Entry: #
# $link_url{"edit_entry"} = http://www.livejournal.com/editjournal.bml?journal=exampleusername&itemid=256 #
# $link_caption{"edit_entry"} = Edit Entry #
# $link_image{"edit_entry"} = http://stat.livejournal.com/img/btn_edit.gif #
# #
# Edit Tags: #
# $link_url{"edit_tags"} = http://www.livejournal.com/edittags.bml?journal=exampleusername&itemid=256 #
# $link_caption{"edit_tags"} = Edit Tags #
# $link_image{"edit_tags"} = http://stat.livejournal.com/img/btn_edittags.gif #
# #
# Add to Memories: #
# $link_url{"mem_add"} = http://www.livejournal.com/tools/memadd.bml?journal=exampleusername&itemid=256 #
# $link_caption{"mem_add"} = Add to Memories #
# $link_image{"mem_add"} = http://stat.livejournal.com/img/btn_memories.gif #
# #
# If interentry: #
# Next Entry: #
# $link_url{"nav_next"} = http://www.livejournal.com/go.bml?journal=exampleusername&itemid=256&dir=next #
# $link_caption{"nav_next"} = Next Entry #
# $link_image{"nav_next"} = http://stat.livejournal.com/img/btn_next.gif #
#################################################################################################################

# disable images
$link_image{"mem_add"} = "";
$link_image{"edit_entry"} = "";
$link_image{"edit_tags"} = "";
$link_image{"tell_friend"} = "";

# loop thru linkbar and add links to print var
foreach var string link_key ($link_keyseq) {
# if we can do performed action, url will be present
if($link_url{$link_key} != "") {
$print = $print + """ """;
# if image url available, use it
if($link_image{$link_key} != "") {
$print = $print + """
""";
} else {
# else, just use text
$print = $print + "$link_caption{$link_key}";
}
# add a seperator
$print = $print + "
$link_seperator";
}
}

# hack off last seperator
$print = $print->substr(0, $print->length() - $link_seperator->length());

# we're done! let's print it!
print $print;
}

function CommentInfo::print() {
var string text_comment_divider = "";

if($.show_readlink) {
$this->print_readlink();
if($.show_postlink) {
print $text_comment_divider;
}
}
if($.show_postlink) {
$this->print_postlink();
}
}

function Page::lay_print_sidebar () {
var string header = "";
var string content = "";

$header = "Introduction";
$content = "Insert a welcome message here!";

print_box($header, box_item($content));

# $this->lay_print_summary();
$this->lay_print_calendar();
$this->print_linklist();
$this->lay_print_freetext();

$header = "LiveJournal Navigation";
$content = "";
var string nav_key = "";
var string[] nav_order = [];
var string{} nav_url = {"" => ""};
var string{} nav_text = {"" => ""};

$nav_key = "recent";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = $.view_url{"recent"};
$nav_text{$nav_key} = lang_viewname("recent");

$nav_key = "info";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = $.view_url{"userinfo"};
$nav_text{$nav_key} = lang_viewname("userinfo");

$nav_key = "userpics";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = $.journal.userpic_listing_url;
$nav_text{$nav_key} = "Userpics";

$nav_key = "filters";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = "$*SITEROOT/friends/filter.bml";
$nav_text{$nav_key} = "Filters";

$nav_key = "mems";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = "$*SITEROOT/tools/memories.bml?user=$.journal.username";
$nav_text{$nav_key} = "Memories";

$nav_key = "poll";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = "$*SITEROOT/poll/create.bml";
$nav_text{$nav_key} = "Create Poll";

$nav_key = "adv";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = "$*SITEROOT/customize/advanced/";
$nav_text{$nav_key} = "Advanced Customization";

$nav_key = "linklist";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = "$*SITEROOT/manage/links.bml";
$nav_text{$nav_key} = "Manage Links";

$nav_key = "comms";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = "$*SITEROOT/community/manage.bml";
$nav_text{$nav_key} = "Manage Communities";

$nav_key = "recentcomments";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = "$*SITEROOT/tools/recent_comments.bml";
$nav_text{$nav_key} = "Recent Comments";

$nav_key = "bdays";
$nav_order[size($nav_order)] = $nav_key;
$nav_url{$nav_key} = "$*SITEROOT/birthdays.bml?user=$.journal.username";
$nav_text{$nav_key} = "Birthdays";

foreach var string n ($nav_order) {
var string url = $nav_url{$n};
var string text = $nav_text{$n};
$content = $content + box_item(""" $text""");
}

print_box($header, $content);

$header = "An additional column";
$content = "" +
box_item("Insert something here!") +
box_item("Insert something here!");

print_box($header, $content);

$header = "Yet another column";
$content = "" +
box_item("Insert something here!") +
box_item("Insert something here!");

print_box($header, $content);

}

function Page::lay_print_header () {
# this is the order of the links
var string[] views_order = $.views_order;

"""

""";

foreach var string v ($views_order) {
var string url = $.view_url{$v};
var string text = lang_viewname($v);
""" $text""";
}

if($.journal.website_url != "") {
var string url = $.journal.website_url;
var string text = $.journal.website_name != "" ? $.journal.website_name : $*text_website_default_name;
""" $text""";
}

var string[] text;
var string[] url;
var int index = 0;

# copy sets as necessary

$text[$index] = "Update";
$url[$index] = "$*SITEROOT/update.bml";
$index++;

$text[$index] = "Memories";
$url[$index] = "$*SITEROOT/tools/memories.bml?user=$.journal.username";
$index++;

foreach var int i (0 .. (size($text) - 1)){
""" $text[$i]""";
}
"""
""";
}

function Page::lay_make_username(Entry e) {
"""

$e.poster""";
}

function Page::print_entry (Entry e) {

print """""";
var string time = $e.time->time_format();
var string date = $e.time->date_format();
var string security;
if ($e.security != "") {
$security = $e.security_icon->as_string();
}

var UserLite name;
var string pname;
var bool show_name = ($.view == "friends") or (not $e.poster->equals($e.journal));
var bool show_pic = (defined $e.userpic and ((not $e.poster->equals($e.journal)) or ($*show_entry_userpic)));

"""

""";
if($show_pic) {
"""



""";
}
var string subject = $e.subject != "" ? $e.subject : """$*text_nosubject""";
"""

$subject

$security posted on: $date @ $time
""";
if($show_name) {
$this->lay_make_username($e);
}
var int count = 0;
var string tags = "";
var string tags_root = $.journal->base_url() + "/tag";
foreach var Tag t ($e.tags) {
$tags = $tags + """ $t.name""";
if(++$count < size($e.tags)) {
$tags = $tags + ", ";
}
}
if($tags != "" and $*tags_aware) {
$tags = "Tags: " + $tags;
}
"""

$tags

"""; $e->print_text(); """
""";
$e->print_metadata();
"""

""";
$e.comments->print();
$e->print_linkbar();
"""

back to top

""";
}

function Page::lay_print_subnav() {
var string prev_url = "";
var string prev_text = $*text_back;
var string next_url = "";
var string next_text = $*text_forward;
var string text = "Viewing ";

if($this isa RecentPage) {
var RecentPage rp = $this as RecentPage;
var int start = $rp.nav.skip;
var int end = $rp.nav.skip + size $rp.entries;
$text = $text + " $start - $end";

$prev_url = $rp.nav.backward_url;
$next_url = $rp.nav.forward_url;
}
if($this isa YearPage) {
var YearPage yp = $this as YearPage;

# $prev_url = $rp.nav.backward_url;
# $next_url = $rp.nav.forward_url;
}
if($this isa MonthPage) {
var MonthPage mp = $this as MonthPage;
$text = $text + " " + $mp.date->date_format("%%month%% %%yyyy%%");

$prev_url = $mp.prev_url;
$next_url = $mp.next_url;
}
if($this isa DayPage) {
var DayPage dp = $this as DayPage;
$text = $text + " " + $dp.date->date_format();

$prev_url = $dp.prev_url;
$next_url = $dp.next_url;
}
if($this isa EntryPage) {
var EntryPage ep = $this as EntryPage;
$text = $text + " " + $ep.view;

var Link prev = $ep.entry->get_link("nav_prev");
var Link next = $ep.entry->get_link("nav_next");
$prev_url = $prev.url;
$next_url = $next.url;
}
if($this isa ReplyPage) {
var ReplyPage rp = $this as ReplyPage;
$text = $text + " " + $rp.view;

var Link prev = $rp.entry->get_link("nav_prev");
var Link next = $rp.entry->get_link("nav_next");
$prev_url = $prev.url;
$next_url = $next.url;
}

if($prev_url != "" or $next_url != "") {
var string back = $prev_url != "" ? """ $prev_text""" : "";
var string forward = $next_url != "" ? """ $next_text""" : "";
"""

$back
$text
$forward

""";
}
}

function FriendsPage::lay_make_username (Entry e) {
var Friend f = $.friends{$e.journal.username};
var string url = $e.poster->base_url();
"""

$e.poster.username""";
if(not $e.poster->equals($e.journal)) {
""" $e.journal""";
}
"""
""";
}

function EntryPage::print_comment(Comment c) {
var string symb;
if ($c.metadata{"picture_keyword"}!=""){
$symb = ": ";
}
var string picword;
if (defined $c.userpic and $*comment_userpic_style !="off") {
$picword = $c.poster.name + $symb + $c.metadata{"picture_keyword"};
}
var string datetime;
$datetime = $c.time->date_format()+", " + $c.time->time_format();

var string parent;
var string thread;
if($c.parent_url != "") {
$parent = """ $*text_comment_parent """;
}
if($c.thread_url != "") {
$thread = """ $*text_comment_thread """;
}

var string subjecticon;
if (defined $c.subject_icon) {
$subjecticon = """
""";
}

var string ip;
if ($c.metadata{"poster_ip"}) {
$ip = """ """ + $c.metadata{"poster_ip"};
}

var string poster = defined $c.poster ? $c.poster->as_string() : "(Anonymous)";

var string pic;
if (defined $c.userpic and $*comment_userpic_style != "off") {
$pic = """

""";
}

var string indent = ($c.depth - 1) * 25 + "px";
"""


$pic

$subjecticon

$poster $ip

on $datetime

""";
if ($.multiform_on) {
"""$*text_multiform_check """;
$c->print_multiform_check();
}

var string replyurl;
if ($c.frozen) {
$replyurl = """ $*text_comment_frozen """;
} else {
$replyurl = """ $*text_comment_reply """;
}
print $replyurl;

# some links for doing stuff to this comment
foreach var string k ($c.link_keyseq) {
var Link link = $c->get_link($k);
if ($link) {
""" $link.caption """;
}
}
"""
$*text_permalink $parent$thread

$c.subject

"""; $c->print_text(); """

""";
if ((size $c.replies) > 0 and $c.replies[0].full == false) {
"""
\n""";
$this->print_comments($c.replies);
"\n";
}
"""

""";
if ((size $c.replies) > 0 and $c.replies[0].full == true) {
$this->print_comments($c.replies);
}
}

function ReplyPage::print_body() {
var EntryLite e = $.replyto;
var string poster = defined $e.poster ? $e.poster->as_string() : "(Anonymous)";
var string datetime;
var string time = $e.time->time_format();
var string date = $e.time->date_format();

var UserLite name;
if(defined $e.userpic and $*comment_userpic_style != "off") {
$name = $e.poster;
"""

""";
if (defined $e.userpic or (defined $e.userpic and $.view == "entry" and $*show_entry_userpic)) {
"""

""";
}
"""
""";
}
"""

$name

$time $date

$*text_reply_back """;
$.entry->print_linkbar();
var string subject = $e.subject != "" ? $e.subject : """$*text_nosubject""";
"""
$*text_permalink

$subject

""";
$e->print_text();
"""

""";
$.form->print();
"""

""";
}

function Page::print () {
var string header_url = "";
var int journal_width = 650;

var string title = $this->title();
"""

$title

""";
$this->print_head();
"""


""";
$this->print_control_strip();
"""

""";

if($header_url != "") {
"""

""";
}

"""

""";
# $this->lay_print_username();
$this->lay_print_header();
"""

""";
# $this->lay_print_userpic();
$this->lay_print_sidebar();
"""

""";
$this->print_body();
$this->lay_print_subnav();
"""

""";
}

function print_entry, class entry, function lay_print_subnav, class replypage, function print_linkbar, function print_comment, function lay_print_header, layout opal, class commentinfo, function print, function print_metadata, function print_stylesheet, c

Previous post Next post
Up