<commit_before><!DOCTYPE html>
<html lang=en>
<head>
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	
 <!-- <script src="monocle/scripts/monocore.js"></script> -->
 <!-- MONOCLE CORE -->
 <script type="text/javascript" src="src/core/monocle.js"></script>
 <script type="text/javascript" src="src/compat/env.js"></script>
 <script type="text/javascript" src="src/compat/css.js"></script>
 <script type="text/javascript" src="src/compat/stubs.js"></script>
 <script type="text/javascript" src="src/compat/browser.js"></script>
 <script type="text/javascript" src="src/core/events.js"></script>
 <script type="text/javascript" src="src/core/factory.js"></script>
 <script type="text/javascript" src="src/core/styles.js"></script>
 <script type="text/javascript" src="src/core/reader.js"></script>
 <script type="text/javascript" src="src/core/book.js"></script>
 <script type="text/javascript" src="src/core/component.js"></script>
 <script type="text/javascript" src="src/core/place.js"></script>

 <!-- MONOCLE FLIPPERS -->
 <script type="text/javascript" src="src/controls/panel.js"></script>
 <script type="text/javascript" src="src/panels/twopane.js"></script>
 <script type="text/javascript" src="src/panels/marginal.js"></script>
 <script type="text/javascript" src="src/panels/imode.js"></script>
 <script type="text/javascript" src="src/panels/eink.js"></script>
 <script type="text/javascript" src="src/dimensions/columns.js"></script>
 <script type="text/javascript" src="src/flippers/slider.js"></script>
 <script type="text/javascript" src="src/flippers/instant.js"></script>
 <script type="text/javascript" src="src/dimensions/vert.js"></script>
 <script type="text/javascript" src="src/flippers/legacy.js"></script>
 <!-- MONOCLE STANDARD CONTROLS -->
   <script type="text/javascript" src="src/controls/spinner.js"></script>
    <script type="text/javascript" src="src/controls/magnifier.js"></script>

    <script type="text/javascript" src="src/controls/scrubber.js"></script>
    <script type="text/javascript" src="src/controls/placesaver.js"></script>
    <script type="text/javascript" src="src/controls/contents.js"></script>
  <link rel="stylesheet" type="text/css" href="monocle/styles/monocore.css" />
  <link rel="stylesheet" type="text/css" href="monocle/styles/monoctrl.css" />
  <style>
    #reader { width: 300px; height: 400px; border: 1px solid #000; }
	#part1, #part2 {display:none}
  </style>
<meta charset="UTF-8">

<title>AST</title>
<script src="data.php"></script>
<script>
var dontturn;
var runningP0;
var runningP1;
var runningP2;
var runningP3;
var runningP4;
var runningP5;
var runningP6;
var runningP7;
var runningP8;
var runningP9;
var audio;
function init(){
	console.log("init");
	// window.reader = Monocle.Reader('reader');
	
	// I-MODE
    // window.reader = Monocle.Reader(
    //   'imode',
    //   'reader',
    //   { panels: Monocle.Panels.IMode }
    // );

	audioz = document.getElementById("audio");
	
	audioz.addEventListener("abort", 		function () {	debug(arguments, "abort"); });
	audioz.addEventListener("canplay", 		function () {	debug(arguments, "canplay"); });
	audioz.addEventListener("canplaythrough", 	function () {	debug(arguments, "canplaythrough"); });
	audioz.addEventListener("durationchange", 	function () {	debug(arguments, "durationchange"); });
	audioz.addEventListener("emptied", 		function () {	debug(arguments, "emptied"); });
	audioz.addEventListener("ended", 		function () {	debug(arguments, "ended"); });
	audioz.addEventListener("error", 		function () {	debug(arguments, "error"); });
	audioz.addEventListener("loadeddata", 		function () {	debug(arguments, "loadeddata"); });
	audioz.addEventListener("loadedmetadata", 	function () {	debug(arguments, "loadedmetadata"); });
	audioz.addEventListener("loadstart", 		function () {	debug(arguments, "loadstart"); });
	audioz.addEventListener("pause", 		function () {	debug(arguments, "pause"); });
	audioz.addEventListener("play", 			function () {	debug(arguments, "play"); });
	audioz.addEventListener("playing", 		function () {	debug(arguments, "playing"); });
	audioz.addEventListener("progress", 		function () {	debug(arguments, "progress"); });
	audioz.addEventListener("ratechange", 		function () {	debug(arguments, "ratechange"); });
	audioz.addEventListener("readystatechange", 	function () {	debug(arguments, "readystatechange"); });
	audioz.addEventListener("seeked", 		function () {	debug(arguments, "seeked"); });
	audioz.addEventListener("seeking", 		function () {	debug(arguments, "seeking"); });
	audioz.addEventListener("stalled", 		function () {	debug(arguments, "stalled"); });
	audioz.addEventListener("suspend", 		function () {	debug(arguments, "suspend"); });
	audioz.addEventListener("volumechange", 		function () {	debug(arguments, "volumechange"); });
	audioz.addEventListener("waiting", 		function () {	debug(arguments, "waiting"); });
	audioz.addEventListener("timeupdate", 		function () {	update(arguments); });
	dontturn = false;
	runningP0 = false;
 	runningP1 = false;
 	runningP2 = false;
 	runningP3 = false;
 	runningP4 = false;
 	runningP5 = false;
 	runningP6 = false;
	runningP7 = false;
 	runningP8 = false;
 	runningP9 = false;
	startRunP(0);
	//var place = reader.getPlace();
    //document.getElementById('currentpar').innerHTML = place.chapterTitle();
	//reader.addControl(new Monocle.Controls.Scrubber(reader)) 

		reader.listen(
		'monocle:pagechange',
		function (evt) {
		var place = reader.getPlace(evt.m.page);
		var section = place.componentId();
		var chapterInfo = place.chapterInfo();
		var chapterSrc = place.chapterSrc();
		var pageTopPos = place.percentAtTopOfPage();
		var pageBottomPos = place.percentAtBottomOfPage();
		var pagenumber = place.pageNumber() - 1;
		document.getElementById('pagenum').innerHTML = "Page "+ pagenumber;
		
	
		});
		
	

		  /* MAGNIFIER CONTROL */
          var magnifier = new Monocle.Controls.Magnifier(reader);
          reader.addControl(magnifier, 'page');





//setTimeout("reader.moveTo({ direction: 1 })",6000);

}



function update(){
	var status = document.getElementById("status");
	//status.innerHTML = audioz.currentTime + "<br />";
	for (var i=0; i<timeline.length; i++){
		
	}
}

function time2secs(t){
	var secs = (Number(t.toString().substr(0,2))*3600) + (Number(t.toString().substr(3,2))*60) + (Number(t.toString().substr(6,2)));
	return Number(secs) + Number(timeline.offset);
}
<commit_msg>added scrubber and zoom controls<commit_after><!DOCTYPE html>
<html lang=en>
<head>
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	
 <!-- <script src="monocle/scripts/monocore.js"></script> -->
 <!-- MONOCLE CORE -->
 <script type="text/javascript" src="src/core/monocle.js"></script>
 <script type="text/javascript" src="src/compat/env.js"></script>
 <script type="text/javascript" src="src/compat/css.js"></script>
 <script type="text/javascript" src="src/compat/stubs.js"></script>
 <script type="text/javascript" src="src/compat/browser.js"></script>
 <script type="text/javascript" src="src/core/events.js"></script>
 <script type="text/javascript" src="src/core/factory.js"></script>
 <script type="text/javascript" src="src/core/styles.js"></script>
 <script type="text/javascript" src="src/core/reader.js"></script>
 <script type="text/javascript" src="src/core/book.js"></script>
 <script type="text/javascript" src="src/core/component.js"></script>
 <script type="text/javascript" src="src/core/place.js"></script>

 <!-- MONOCLE FLIPPERS -->
 <script type="text/javascript" src="src/controls/panel.js"></script>
 <script type="text/javascript" src="src/panels/twopane.js"></script>
 <script type="text/javascript" src="src/panels/marginal.js"></script>
 <script type="text/javascript" src="src/panels/imode.js"></script>
 <script type="text/javascript" src="src/panels/eink.js"></script>
 <script type="text/javascript" src="src/dimensions/columns.js"></script>
 <script type="text/javascript" src="src/flippers/slider.js"></script>
 <script type="text/javascript" src="src/flippers/instant.js"></script>
 <script type="text/javascript" src="src/dimensions/vert.js"></script>
 <script type="text/javascript" src="src/flippers/legacy.js"></script>
 <!-- MONOCLE STANDARD CONTROLS -->
   <script type="text/javascript" src="src/controls/spinner.js"></script>
    <script type="text/javascript" src="src/controls/magnifier.js"></script>

    <script type="text/javascript" src="src/controls/scrubber.js"></script>
    <script type="text/javascript" src="src/controls/placesaver.js"></script>
    <script type="text/javascript" src="src/controls/contents.js"></script>
  <link rel="stylesheet" type="text/css" href="monocle/styles/monocore.css" />
  <link rel="stylesheet" type="text/css" href="monocle/styles/monoctrl.css" />
  <style>
    #reader { width: 300px; height: 400px; border: 1px solid #000; }
	#part1, #part2 {display:none}
  </style>
<meta charset="UTF-8">

<title>AST</title>
<script src="data.php"></script>
<script>
var dontturn;
var runningP0;
var runningP1;
var runningP2;
var runningP3;
var runningP4;
var runningP5;
var runningP6;
var runningP7;
var runningP8;
var runningP9;
var audio;
function init(){
	console.log("init");
	// window.reader = Monocle.Reader('reader');
	
	// I-MODE
    // window.reader = Monocle.Reader(
    //   'imode',
    //   'reader',
    //   { panels: Monocle.Panels.IMode }
    // );

	audioz = document.getElementById("audio");
	
	audioz.addEventListener("abort", 		function () {	debug(arguments, "abort"); });
	audioz.addEventListener("canplay", 		function () {	debug(arguments, "canplay"); });
	audioz.addEventListener("canplaythrough", 	function () {	debug(arguments, "canplaythrough"); });
	audioz.addEventListener("durationchange", 	function () {	debug(arguments, "durationchange"); });
	audioz.addEventListener("emptied", 		function () {	debug(arguments, "emptied"); });
	audioz.addEventListener("ended", 		function () {	debug(arguments, "ended"); });
	audioz.addEventListener("error", 		function () {	debug(arguments, "error"); });
	audioz.addEventListener("loadeddata", 		function () {	debug(arguments, "loadeddata"); });
	audioz.addEventListener("loadedmetadata", 	function () {	debug(arguments, "loadedmetadata"); });
	audioz.addEventListener("loadstart", 		function () {	debug(arguments, "loadstart"); });
	audioz.addEventListener("pause", 		function () {	debug(arguments, "pause"); });
	audioz.addEventListener("play", 			function () {	debug(arguments, "play"); });
	audioz.addEventListener("playing", 		function () {	debug(arguments, "playing"); });
	audioz.addEventListener("progress", 		function () {	debug(arguments, "progress"); });
	audioz.addEventListener("ratechange", 		function () {	debug(arguments, "ratechange"); });
	audioz.addEventListener("readystatechange", 	function () {	debug(arguments, "readystatechange"); });
	audioz.addEventListener("seeked", 		function () {	debug(arguments, "seeked"); });
	audioz.addEventListener("seeking", 		function () {	debug(arguments, "seeking"); });
	audioz.addEventListener("stalled", 		function () {	debug(arguments, "stalled"); });
	audioz.addEventListener("suspend", 		function () {	debug(arguments, "suspend"); });
	audioz.addEventListener("volumechange", 		function () {	debug(arguments, "volumechange"); });
	audioz.addEventListener("waiting", 		function () {	debug(arguments, "waiting"); });
	audioz.addEventListener("timeupdate", 		function () {	update(arguments); });
	dontturn = false;
	runningP0 = false;
 	runningP1 = false;
 	runningP2 = false;
 	runningP3 = false;
 	runningP4 = false;
 	runningP5 = false;
 	runningP6 = false;
	runningP7 = false;
 	runningP8 = false;
 	runningP9 = false;
	startRunP(0);
	//var place = reader.getPlace();
    //document.getElementById('currentpar').innerHTML = place.chapterTitle();
	//reader.addControl(new Monocle.Controls.Scrubber(reader)) 

		reader.listen(
			'monocle:pagechange',
			function (evt) {
			var place = reader.getPlace(evt.m.page);
			var section = place.componentId();
			var chapterInfo = place.chapterInfo();
			var chapterSrc = place.chapterSrc();
			var pageTopPos = place.percentAtTopOfPage();
			var pageBottomPos = place.percentAtBottomOfPage();
			var pagenumber = place.pageNumber() - 1;
			document.getElementById('pagenum').innerHTML = "Page "+ pagenumber;
		});
		

	    var scrubber = new Monocle.Controls.Scrubber(reader);
        reader.addControl(scrubber);

		  /* MAGNIFIER CONTROL */
          var magnifier = new Monocle.Controls.Magnifier(reader);
          reader.addControl(magnifier);





//setTimeout("reader.moveTo({ direction: 1 })",6000);

}



function update(){
	var status = document.getElementById("status");
	//status.innerHTML = audioz.currentTime + "<br />";
	for (var i=0; i<timeline.length; i++){
		
	}
}

function time2secs(t){
	var secs = (Number(t.toString().substr(0,2))*3600) + (Number(t.toString().substr(3,2))*60) + (Number(t.toString().substr(6,2)));
	return Number(secs) + Number(timeline.offset);
}

{'fraction_non_alphanumeric': 0.1896326968790737, 'fraction_numerical': 0.008588298443370907, 'mean_word_length': 5.282273603082851, 'pattern_counts': {'":': 0, '<': 155, '<?xml version=': 0, '>': 153, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1906953', 'n_tokens_mistral': 4346, 'n_tokens_neox': 4137, 'n_words': 710}