Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

"Sublime Text 2" like scrolling with javascript / jQuery

i'm trying to implement a Sublime 2 like scrolling bar with code preview in javascript / jquery.

enter image description here

Are there any plugins or code snippets out there which are trying to achieve the same?

like image 293
Julian Hollmann Avatar asked Nov 07 '11 10:11

Julian Hollmann


2 Answers

You can use this jQuery plugin: http://larsjung.de/fracs/ and there is also a demo (exactly what you are looking for: http://larsjung.de/fracs/demo).

like image 149
Misha Reyzlin Avatar answered Nov 20 '22 08:11

Misha Reyzlin


I created a new project to do exactly this. It copies the content into an iframe and scales it down using css. So no canvas, no CORS issues and dimensions are correct.
https://github.com/demux/sublime-scroll/

like image 9
demux Avatar answered Nov 20 '22 07:11

demux