diff --git a/ChangeLog b/ChangeLog index 1a2a305..d7ea959 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,6 +3,8 @@ * Fix some scaling related issues. This fix is thanks to some excellent detective work by Jan . + * Allow changing of font sizes in the user CSS. + 2010-08-19 Markus Gutschke * Thanks to lotr44's excellent analysis of the problem, we now have diff --git a/config.h b/config.h index 43cf6d9..c9fe702 100644 --- a/config.h +++ b/config.h @@ -153,7 +153,7 @@ #define STDC_HEADERS 1 /* Most recent revision number in the version control system */ -#define VCS_REVISION "218" +#define VCS_REVISION "219" /* Version number of package */ #define VERSION "2.10" diff --git a/configure b/configure index ba1bfc6..be80a0b 100755 --- a/configure +++ b/configure @@ -2328,7 +2328,7 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $ ac_compiler_gnu=$ac_cv_c_compiler_gnu -VCS_REVISION=218 +VCS_REVISION=219 cat >>confdefs.h <<_ACEOF diff --git a/configure.ac b/configure.ac index 05786e5..740224b 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ AC_PREREQ(2.57) dnl This is the one location where the authoritative version number is stored AC_INIT(shellinabox, 2.10, markus@shellinabox.com) -VCS_REVISION=218 +VCS_REVISION=219 AC_SUBST(VCS_REVISION) AC_DEFINE_UNQUOTED(VCS_REVISION, "${VCS_REVISION}", [Most recent revision number in the version control system]) diff --git a/demo/vt100.js b/demo/vt100.js index 6e2dd28..a12b493 100644 --- a/demo/vt100.js +++ b/demo/vt100.js @@ -434,6 +434,18 @@ VT100.prototype.initializeUserCSSStyles = function() { } entry = entry.nextSibling; } + + // If the font size changed, adjust cursor and line dimensions + this.cursor.style.cssText= ''; + this.cursorWidth = this.cursor.clientWidth; + this.cursorHeight = this.lineheight.clientHeight; + for (i = 0; i < this.console.length; ++i) { + for (var line = this.console[i].firstChild; line; + line = line.nextSibling) { + line.style.height = this.cursorHeight + 'px'; + } + } + vt100.resizer(); }; }(this, j, beginOfGroup, i - beginOfGroup); } @@ -1962,7 +1974,7 @@ VT100.prototype.toggleCursorBlinking = function() { }; VT100.prototype.about = function() { - alert("VT100 Terminal Emulator " + "2.10 (revision 218)" + + alert("VT100 Terminal Emulator " + "2.10 (revision 219)" + "\nCopyright 2008-2010 by Markus Gutschke\n" + "For more information check http://shellinabox.com"); }; diff --git a/shellinabox/shell_in_a_box.js b/shellinabox/shell_in_a_box.js index 07a0536..7d46858 100644 --- a/shellinabox/shell_in_a_box.js +++ b/shellinabox/shell_in_a_box.js @@ -358,7 +358,7 @@ ShellInABox.prototype.extendContextMenu = function(entries, actions) { }; ShellInABox.prototype.about = function() { - alert("Shell In A Box version " + "2.10 (revision 218)" + + alert("Shell In A Box version " + "2.10 (revision 219)" + "\nCopyright 2008-2010 by Markus Gutschke\n" + "For more information check http://shellinabox.com" + (typeof serverSupportsSSL != 'undefined' && serverSupportsSSL ? diff --git a/shellinabox/vt100.js b/shellinabox/vt100.js index 6e2dd28..a12b493 100644 --- a/shellinabox/vt100.js +++ b/shellinabox/vt100.js @@ -434,6 +434,18 @@ VT100.prototype.initializeUserCSSStyles = function() { } entry = entry.nextSibling; } + + // If the font size changed, adjust cursor and line dimensions + this.cursor.style.cssText= ''; + this.cursorWidth = this.cursor.clientWidth; + this.cursorHeight = this.lineheight.clientHeight; + for (i = 0; i < this.console.length; ++i) { + for (var line = this.console[i].firstChild; line; + line = line.nextSibling) { + line.style.height = this.cursorHeight + 'px'; + } + } + vt100.resizer(); }; }(this, j, beginOfGroup, i - beginOfGroup); } @@ -1962,7 +1974,7 @@ VT100.prototype.toggleCursorBlinking = function() { }; VT100.prototype.about = function() { - alert("VT100 Terminal Emulator " + "2.10 (revision 218)" + + alert("VT100 Terminal Emulator " + "2.10 (revision 219)" + "\nCopyright 2008-2010 by Markus Gutschke\n" + "For more information check http://shellinabox.com"); }; diff --git a/shellinabox/vt100.jspp b/shellinabox/vt100.jspp index 3fe2a9f..d5c2898 100644 --- a/shellinabox/vt100.jspp +++ b/shellinabox/vt100.jspp @@ -434,6 +434,18 @@ VT100.prototype.initializeUserCSSStyles = function() { } entry = entry.nextSibling; } + + // If the font size changed, adjust cursor and line dimensions + this.cursor.style.cssText= ''; + this.cursorWidth = this.cursor.clientWidth; + this.cursorHeight = this.lineheight.clientHeight; + for (i = 0; i < this.console.length; ++i) { + for (var line = this.console[i].firstChild; line; + line = line.nextSibling) { + line.style.height = this.cursorHeight + 'px'; + } + } + vt100.resizer(); }; }(this, j, beginOfGroup, i - beginOfGroup); }