Index: src/window.cpp
===================================================================
--- src/window.cpp (revision eac9d654e2ab86596ea7589952481779a14f6844)
+++ src/window.cpp (revision 5a41a0aff9b1b43c3fdffdac6b31b3d9dbbe1fa0)
@@ -75,8 +75,11 @@
 		sigc::mem_fun(*this, &Window::on_user_set_password) );
 
+	m_header.document_word_wrap_event().connect(
+		sigc::mem_fun(*this, &Window::on_document_word_wrap) );
 #ifdef WITH_GTKSOURCEVIEW
+	m_header.document_line_numbers_event().connect(
+		sigc::mem_fun(*this, &Window::on_document_line_numbers) );
 	m_header.document_language_event().connect(
 		sigc::mem_fun(*this, &Window::on_document_language) );
-#endif
 
 	m_header.about_event().connect(
@@ -468,5 +471,31 @@
 }
 
+void Gobby::Window::on_document_word_wrap()
+{
+	// Get current page
+	DocWindow& doc_wnd = *static_cast<DocWindow*>(
+		m_folder.get_nth_page(m_folder.get_current_page() )
+	);
+
+	// Toggle word wrapping flag
+	doc_wnd.get_document().set_word_wrapping(
+		!doc_wnd.get_document().get_word_wrapping()
+	);
+}
+
 #ifdef WITH_GTKSOURCEVIEW
+void Gobby::Window::on_document_line_numbers()
+{
+	// Get current page
+	DocWindow& doc_wnd = *static_cast<DocWindow*>(
+		m_folder.get_nth_page(m_folder.get_current_page() )
+	);
+
+	// Toggle line number flag
+	doc_wnd.get_document().set_show_line_numbers(
+		!doc_wnd.get_document().get_show_line_numbers()
+	);
+}
+
 void Gobby::Window::on_document_language(
 	const Glib::RefPtr<Gtk::SourceLanguage>& lang
@@ -481,5 +510,4 @@
 	doc.get_document().set_language(lang);
 }
-#endif
 
 void Gobby::Window::on_quit()
