Open JasonBarnabe opened 11 years ago
What about adding a simple resize gripper in the right bottom corner like this at least?
Implemented in a4f602c7aa4e60dcbaab3e110035662c94788c09
Tried implementing autoresize:
function setupCodeMirror(textarea) {
.................................
cm.display.wrapper.style.height = cm.display.sizer.scrollHeight + 'px';
cm.on("changes", function(cm) {
if (cm.display.wrapper.scrollHeight !== cm.display.sizer.scrollHeight) {
cm.display.wrapper.style.height = cm.display.sizer.scrollHeight + 'px';
}
});
But in very tall sections the cursor sometimes wasn't scrolled into view, probably a Chrome's or CodeMirror's issue, needs more investigation.
Copied from https://github.com/JasonBarnabe/stylish/issues/93
http://forum.userstyles.org/discussion/34496/stylish-chrome-1.1-update-suggestion#Item_11
http://codemirror.net/demo/resize.html
This looks like it would do it, but setting viewportMargin = Infinity makes things noticeably slow even for stylsheets a few hundred lines long.