Browse Source

moka changes
- css improvements related to fonts
- updates MKButtonView >> hasIcon

Nicolas Petton 10 years ago
parent
commit
a1811c6f7b
4 changed files with 22 additions and 14 deletions
  1. 16 8
      css/moka.css
  2. 2 2
      css/moka.less
  3. 3 3
      js/Moka-Views.js
  4. 1 1
      st/Moka-Views.st

+ 16 - 8
css/moka.css

@@ -10,7 +10,8 @@
 }
 .mk_default {
   font-size: 12px;
-  font-family: "Open Sans";
+  font-family: "Open Sans", helvetica, arial, sans;
+  line-height: 1.5em;
   color: #444444;
   text-shadow: 0 1px 0 white;
   padding: 0;
@@ -37,7 +38,8 @@
 }
 .moka_view.mk_label {
   font-size: 12px;
-  font-family: "Open Sans";
+  font-family: "Open Sans", helvetica, arial, sans;
+  line-height: 1.5em;
   color: #444444;
   text-shadow: 0 1px 0 white;
   padding: 0;
@@ -120,7 +122,8 @@
 .moka_view .mk_control:active,
 .moka_view .mk_control:focus {
   font-size: 12px;
-  font-family: "Open Sans";
+  font-family: "Open Sans", helvetica, arial, sans;
+  line-height: 1.5em;
   color: #444444;
   text-shadow: 0 1px 0 white;
   padding: 0;
@@ -154,7 +157,8 @@
 }
 .moka_view.mk_button {
   font-size: 12px;
-  font-family: "Open Sans";
+  font-family: "Open Sans", helvetica, arial, sans;
+  line-height: 1.5em;
   color: #444444;
   text-shadow: 0 1px 0 white;
   padding: 0;
@@ -224,7 +228,8 @@
 .moka_view.mk_input,
 .moka_view.mk_textarea {
   font-size: 12px;
-  font-family: "Open Sans";
+  font-family: "Open Sans", helvetica, arial, sans;
+  line-height: 1.5em;
   color: #444444;
   text-shadow: 0 1px 0 white;
   padding: 0;
@@ -283,7 +288,8 @@
 }
 .moka_view.mk_switch {
   font-size: 12px;
-  font-family: "Open Sans";
+  font-family: "Open Sans", helvetica, arial, sans;
+  line-height: 1.5em;
   color: #444444;
   text-shadow: 0 1px 0 white;
   padding: 0;
@@ -378,7 +384,8 @@
   -ms-user-select: none;
   user-select: none;
   font-size: 12px;
-  font-family: "Open Sans";
+  font-family: "Open Sans", helvetica, arial, sans;
+  line-height: 1.5em;
   color: #444444;
   text-shadow: 0 1px 0 white;
   margin: 0;
@@ -460,7 +467,8 @@
 }
 .moka_view.mk_dropdown {
   font-size: 12px;
-  font-family: "Open Sans";
+  font-family: "Open Sans", helvetica, arial, sans;
+  line-height: 1.5em;
   color: #444444;
   text-shadow: 0 1px 0 white;
   padding: 0;

+ 2 - 2
css/moka.less

@@ -108,8 +108,8 @@
 .mk_default {
     // Generic fonts
     font-size: 12px;
-    font-family: "Open Sans";
-    //line-height: 1.5em;
+    font-family: "Open Sans", helvetica, arial, sans;
+    line-height: 1.5em;
     color: @darker;
     text-shadow: 0 1px 0 white;
     

+ 3 - 3
js/Moka-Views.js

@@ -130,12 +130,12 @@ fn: function (){
 var self=this;
 return smalltalk.withContext(function($ctx1) { 
 var $1;
-$1=_st(self["@icon"])._notNil();
+$1=_st(self._icon())._notNil();
 return $1;
 }, function($ctx1) {$ctx1.fill(self,"hasIcon",{},smalltalk.MKButtonView)})},
 args: [],
-source: "hasIcon\x0a\x09^ icon notNil",
-messageSends: ["notNil"],
+source: "hasIcon\x0a\x09^ self icon notNil",
+messageSends: ["notNil", "icon"],
 referencedClasses: []
 }),
 smalltalk.MKButtonView);

+ 1 - 1
st/Moka-Views.st

@@ -79,7 +79,7 @@ renderContentOn: html
 !MKButtonView methodsFor: 'testing'!
 
 hasIcon
-	^ icon notNil
+	^ self icon notNil
 !
 
 isDefault