zoukankan      html  css  js  c++  java
  • 使用BorderContainer设置背景图片

    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
           xmlns:s="library://ns.adobe.com/flex/spark"    
        xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600">
     <fx:Declarations>
      <!-- 将非可视元素(例如服务、值对象)放在此处 -->
     </fx:Declarations>
     <fx:Style>
      @namespace s "library://ns.adobe.com/flex/spark";
      @namespace mx "library://ns.adobe.com/flex/mx";
      .mybackground {  
       /* backgroundImage: Embed(source="images/b.png");
       backgroundSize: 800px;
       backgroundColor: #cccccc; */   
       font-size:14;   
       /* fontSize:24; ?*/   
       background-image:Embed("../Login/MainTitleBK.png");   
       /*background-position:right,bottom;*/  
       /*background-blend:multiply;*/   
       background-size:"100%";   
       backgroundImageFillMode: repeat;
      } 
      s|Button {   
       cornerRadius: 9;   
       color: #cc0000;  
      }
      .myButton {   
       cornerRadius: 9;  
       color: #00ff00;   
      } 
      s|Panel{  
       backgroundColor: #e8e8e8;  
      } 
     </fx:Style>
     <s:BorderContainer styleName="mybackground" width="100%" height="80" backgroundImageFillMode="repeat" borderStyle="solid" borderWeight="0" borderVisible="false"> 
      <s:Panel x="10" y="10" width="250" height="200" id="panel1" title="用户登录" fontFamily="Georgia" textAlign="left"> 
       <s:Label x="24" y="32" text="用户名" /> 
       <s:Label x="36" y="59" text="密码" /> 
       <s:TextInput x="74" y="27" id="txtUsername"/>   
       <s:TextInput x="74" y="57" id="txtPassword" displayAsPassword="true"/>  
       <s:Button x="36" y="104" label="登录" id="btnLogin"/>   
       <s:Button x="132" y="104" label="重置" id="btnReset" styleName="myButton"/>  
      </s:Panel>  
     </s:BorderContainer> 
    </s:Application>


     

  • 相关阅读:
    [转]Java compiler level does not match解决方法
    Ubuntu使用MyEclipse闪退的解决办法
    支付宝AR红包引出Python中的PIL小试
    Neural Style学习3——操作
    Neural Style学习2——环境安装
    Neural Style学习1——简介
    mac下需要安装旧 Java SE 6 才能打开程序解决办法
    Linux system 函数的一些注意事项
    关于在android 4.2.2 上运行runlmbench
    linux kernel 字符设备详解
  • 原文地址:https://www.cnblogs.com/tianlangshu/p/2498939.html
Copyright © 2011-2022 走看看