Index: inc/table-of-contents.php
===================================================================
--- inc/table-of-contents.php	(revision 3623)
+++ inc/table-of-contents.php	(working copy)
@@ -9,9 +9,17 @@
 
 	protected $styles = '<style> .toc-jump { text-align: right; font-size: 12px; } .page .toc-heading { margin-top: -50px; padding-top: 50px !important; }</style>';
 
-	function __construct( $post_types ) {
+	protected $args = array();
+
+	function __construct( $post_types, $args = array() ) {
 		$this->post_types = (array) $post_types;
 		add_action( 'template_redirect', array( $this, 'load_filters' ) );
+
+		$defaults = array(
+			'header_text' => __( 'Topics', 'wporg' ),
+		);
+
+		$this->args = (object) wp_parse_args( $args, $defaults );
 	}
 
 	function load_filters() {
@@ -41,7 +49,7 @@
 			$contents_header = 'h' . $items[0][2]; // Duplicate the first <h#> tag in the document.
 			$toc .= $this->styles;
 			$toc .= '<div class="table-of-contents">';
-			$toc .= "<$contents_header>" . __( 'Topics', 'wporg' ) . "</$contents_header><ul class=\"items\">";
+			$toc .= "<$contents_header>" . esc_html( $this->args->header_text ) . "</$contents_header><ul class=\"items\">";
 			$last_item = false;
 			foreach ( $items as $item ) {
 				if ( $last_item ) {
