Title display fix
authorveltr
Thu, 28 Mar 2013 18:44:12 +0100
changeset 117 803f14e35431
parent 116 07f9fc847d5d
child 118 c0e03c7137e3
Title display fix
client/css/renkan.css
client/js/paper-renderer.js
client/render-test.html
--- a/client/css/renkan.css	Wed Mar 27 18:11:18 2013 +0100
+++ b/client/css/renkan.css	Thu Mar 28 18:44:12 2013 +0100
@@ -83,10 +83,18 @@
 }
 
 .Rk-PadTitle {
-    float: left; font-size: 14px; height: 16px; margin: 4px 5px; width: 180px; background: #666666; padding: 4px; border: 1px solid #333333;
+    float: left; font-size: 14px; height: 16px; margin: 4px 5px; background: #666666; padding: 4px; border: 1px solid #333333;
     border-radius: 3px; box-shadow: 0 1px 0 #505050; color: #ffffff; font-weight: bold;
 }
 
+input.Rk-PadTitle {
+    width: 180px;
+}
+
+h2.Rk-PadTitle {
+    min-width: 180px; max-width: 320px; overflow: hidden;
+}
+
 .Rk-Users {
     float: right; width: 130px; margin: 4px 5px;
 }
--- a/client/js/paper-renderer.js	Wed Mar 27 18:11:18 2013 +0100
+++ b/client/js/paper-renderer.js	Thu Mar 28 18:44:12 2013 +0100
@@ -1688,7 +1688,6 @@
 }
 
 Rkns.Renderer.Scene.prototype.autoScale = function() {
-	console.log("Autoscale")
     var nodes = this.renkan.project.get("nodes")
     if (nodes.length > 1) {
         var _xx = nodes.map(function(_node) { return _node.get("position").x }),
@@ -1698,8 +1697,7 @@
             _maxx = Math.max.apply(Math, _xx),
             _maxy = Math.max.apply(Math, _yy);
         var _scale = Math.min((paper.view.size.width - 2 * Rkns.Renderer._AUTOSCALE_MARGIN) / (_maxx - _minx), (paper.view.size.height - 2 * Rkns.Renderer._AUTOSCALE_MARGIN) / (_maxy - _miny));
-		console.log(_minx, _miny, _maxx, _maxy, _scale);
-        this.offset = paper.view.center.subtract(new paper.Point([(_maxx + _minx) / 2, (_maxy + _miny) / 2]).multiply(_scale));
+		this.offset = paper.view.center.subtract(new paper.Point([(_maxx + _minx) / 2, (_maxy + _miny) / 2]).multiply(_scale));
         this.setScale(_scale);
     }
     if (nodes.length === 1) {
--- a/client/render-test.html	Wed Mar 27 18:11:18 2013 +0100
+++ b/client/render-test.html	Thu Mar 28 18:44:12 2013 +0100
@@ -26,7 +26,6 @@
             var _renkan;
             $(function() {
                 _renkan = new Rkns.Renkan({
-                	read_only: true,
                     url: "data/simple-persist.php",
                     bins: [
                     	{