Free Republic Tree ViewerFree Republic Tree Viewer (FRTV) is a user script designed to make it easier to read discussion threads on Free Republic, a political forum. Free Republic has an excellent forum implementation, custom designed by the site's founder, Jim Robinson. It's head and shoulders above the junk that powers most other forums on the net. But there is always room for improvement.
FRTV is a "user script". It modifies Free Republic thread pages on the fly, after they have been downloaded by your browser. It supplies additional functionality designed to make it easier to follow the conversational interplay between thread contributors.
Click here to skip to installation. You must be running Firefox with the Greasemonkey extension installed.
FRTV performs the following enhancements on Free Republic threads:
Tree View TransformationNormally, the posts in a Free Republic thread are listed in chronological (post number) order. This is the flat view. Replies to a given post are scattered down through the thread. FR provides a View Replies link to check for replies, but it incurs a server delay and, in any case, only shows the first level of replies, not the replies to the replies, etc.
FRTV can rearrange a thread's posts such that each one has its replies indented beneath it, and each reply in turn has its replies indented beneath it, etc., in a tree structure. We call this the tree view. By bringing replying posts closer to the post to which they are in reply, the tree view makes it easier to follow the various conversations that develop on a thread.
FRTV provides a button and a keyboard shortcut to toggle back and forth between the flat view and the tree view.
Post QuotingPost quoting is simpler function, also designed to make it easier to follow a thread's conversations. FRTV adds a Quote button after the To link in each post having a To link. Pressing the Quote button makes a copy of the post to which the current post is in reply (the object of the To link) and displays it in a shaded box directly above the current post.
The To link still works, of course, but you will find the Quote button less disruptive to the browsing experience. The To link sends you to the post; the Quote button brings the post to you. Now, when you come across, e.g., post #216 replying "LOL!" to post #6, you can simply press the Quote button to view the big joke the lazy poster failed to quote.
Also, if a post mentions another post by number, you see the other post quoted by first selecting the text containing the number before hitting the Quote button.
The Quote button and the To link are available in both the flat and tree views.
The Poster ReportFRTV can scan a thread and display a statistical report on the contributors to the thread in a popup window. The report lists the contributors and gives some basic statistics about their activity on the thread.
Blank Line RemovalDid you ever notice those extraneous blank lines that crop up at the bottom of some of the posts? Well, FRTV eliminates them!
Article Redirect RemovalFRTV edits the article link at the top of a thread (the one decorated with a circumflex) to go directly to the article instead of detouring through a page that reminds you what you already know, namely that you are leaving the FR site.
InstallationTo use FRTV, make sure that you are running Firefox with the Greasemonkey extension installed. Then click here to install FRTV. Greasemonkey will show a dialog allowing you to approve the installation (or view the source if you wish). FRTV has been tested with Firefox 1.5 and 2.0 and Greasemonkey 0.6.8.
UsageOn page load, FRTV performs the blank line and article redirect edits and adds Quote buttons to the posts, as well as buttons and keyboard shortcuts to access the tree view and poster report functions.
Using the Tree View
Click to enlarge
Once the tree view is showing, the button changes to Flat View. Clicking the button (or keying Ctrl-Alt-T) reverts the display back to the original and changes the button back to View as Tree.
In the tree view, replying posts are indented in shaded boxes beneath the posts to which they are in reply. To help the eye track the indentation level, the background color changes cyclically. All of the posts at a particular indentation level have the same background color.
Normally, the only post at the outermost level will be #1. However, if a thread has any deleted posts, these will also placed at the outermost level, with their reply trees beneath them. This is because deleted posts no longer contain a link back to their reply targets.
The Scroll Box
If you click the Dn or the Up button, the page scrolls down or up, respectively, past the scroll box until it reaches a post at the same or outer indentation level as that of the scroll box. The scroll box's indentation level is indicated both by its horizontal position and by its background color. If you bring it up, and it doesn't have the expected color, press the mouse in the background area and drag it left or right until the background changes to the proper color. To dismiss the scroll box, click its close button in the upper right.
Normally, hitting the Dn or Up button causes an animated scroll. That is to say, instead of simply repositioning the display at the end point of the scroll (a jump scroll), FRTV scrolls in a series of rapid, short increments, allowing the page to be displayed at its intermediate position after each increment, thus making the page appear to fly past the stationary scroll box until it reaches the destination. The effect gives you a sense of how far the scroll moved. The animation aims to complete the scroll in constant time (half a second). Therefore, the display moves more quickly the longer the distance to be covered.
If you want a jump scroll instead of the animation, hold down the Ctrl or Alt keys when clicking the Dn or Up button. Also, a click in the indentation area will stop a scroll animation.
You can change or drop the animation feature. See Customization below.
Using the Quote Button
Click to enlarge
Of course, the quoted post also contains a quote button (unless it's the #1 post or a deleted post). Thus, by repeatedly clicking Quote, you can follow the reply chain all the way to the top.
Note: The Quote button can also quote posts which are mentioned by number in the text of a post. Use the mouse to select the number(s) of the posts you would like to see quoted. Then click the Quote button. It will quote the referenced post(s) instead of the post to which the current post is in reply. It ignores non-numeric text in the selection; thus, if a post directs you to "see my posts #37 and 41", you would select that text, and it would quote #37 and #41.
The Quote button is available in the tree view as well as the flat view.
Obtaining a Poster Report
Click to enlarge
The poster report contains a table listing each contributor to the thread along with the length of time (in days, weeks, months, or years) the user has been registered at Free Republic, the number of posts the user has made on the current thread, the number of replies the user has received, and the reply / post ratio. Clicking on a table heading sorts the table by the corresponding column or reverses the order if the table is already sorted on the column. Clicking on a poster's name pops up the poster's FR home page. The name of the user who posted the thread is bolded.
Initially, the posters are listed in order of their first appearance on the thread. The left-most column, headed Rank, indicates a user's ranking in the current sort order (e.g., rank 3 would be third oldest if the table is sorted by FR Age). If you have sorted the table, clicking on the Rank heading sorts the table back into poster appearance order.
At the bottom of the report are some thread statistics, including the number of posts and deleted posts, the number of contributors, the posts per contributor, and the average Free Republic tenure. The posts per contributor statistic gives an indication of how close knit the discussion group is.
Large Thread ConsiderationsMost threads on Free Republic are short. I would estimate the average thread length to be around 35 posts and the median even lower, probably around 20. However, there are some extremely long threads. For the reasons outlined below, I don't recommend invoking the tree view or the poster report on very long threads. However, the Quote button will not be a problem even on a very long thread.
The tree view and the poster report both operate on the thread in its entirety. If a thread spans multiple pages, either operation will trigger the loading of all of its pages in the background (unless the full thread has already been loaded as a result of an earlier operation). How long this will take depends on the following, in roughly descending order of importance:
- The size of the thread
- The speed of your internet connection
- How busy the FR server is
- How fast your computer is (and whether it's short of memory)
The Progress BoxWhenever FRTV is fetching pages in the background, it pops up a floating progress report box which looks like this:
If you wish to abandon an over-long request, click the Cancel button. The operation will abort at the conclusion of the next page load. Refreshing the page or navigating away will also abort the background activity. Either operation basically reboots FRTV, requiring it to rebuild its data structures from scratch.
Changing Your Page SizeIf you are logged into Free Republic, you can change your thread page size. Go to the Settings page and select the Thread Pagination value you want. The default is 50 posts per page. You can set it as high as 250. At 250 posts per page, most threads will fit into a single page.
CustomizationIf you edit the script, you can make some customizations by changing some constants near the top of the file. Right-click the monkey face in the status bar and select Manage User Scripts.... Then select "FR Tree Viewer" and click Edit. Remember to backup your modified script. If you install an updated version of FRTV, you will need to reapply your changes.
The constants are marked with const declarations. Items you might want to change:
- StylesThe CSS styles that apply to elements added by FRTV are mostly contained in the STYLES constant. For instance, if you would like the quoted posts to have a pale blue background instead of pale yellow, you could change the background in the .quoteBox style from #ffc to #ccf. Or, for a white background, you could set it to #fff or remove the background property altogether.
- Indentation IncrementTo change the amount of indentation applied to replying posts in the tree view, change the INDENT constant.
- Maximum IndentationOn some threads, the reply nesting in the tree view can get out of hand, causing the posts to march off the right edge of the screen. This happens infrequently. But when it does, FRTV stops further indentation when the indent level reaches a certain fraction of the screen width (at the time the tree view was selected). The MAX_INDENT sets the indentation limit.
- Tree View Background ColorsIn the tree view, the background color of the post box changes cyclically with increasing indentation. The colors used are those listed in the BACKGROUNDS array. To have just alternating yellow and green, you could change the array to ['#ffc', '#cfc']. To turn off coloring, you could change the array to just ['#fff'].
- Scroll AnimationThe SCROLL constant parameterizes the tree view's scroll box scroll animation. Three modes are available: constant-time (the default), constant-speed, and jump scroll (no animation). To select the mode, change the 'method' property to 'constantTime', 'constantSpeed', or 'jump'. You can further parameterize the two animation modes:
- constantTime: The page performs intervalCount jumps at intervals of timeInterval milliseconds. Thus, the product of the two parameters is roughly how long a scroll will take, and the distance of each jump depends on the total distance to be scrolled.
- constantSpeed: The page jumps pixelsPerInterval pixels every timeInterval milliseconds, until the distance to be scrolled is covered.