用戶界面標記語言

本頁使用了標題或全文手工轉換
維基百科,自由的百科全書

用戶界面標記語言user interface markup language)是一類渲染和描繪圖形用戶界面控件置標語言。此類標記語言很多都是XML的方言,並且依賴於已經存在的腳本語言引擎(通常為JavaScript引擎)來渲染控件和額外的腳本。

用戶界面標記語言的概念主要基於用戶界面的設計,避免用戶界面設計、開發和功能上的「重造輪子」,諸如重新編寫、發明整個用戶界面。典型的用戶界面標記語言以標記形式固化經常重用的程序或腳本代碼,使其更容易以可理解的語言來設計用戶界面,而不是專注於具體的功能。

用戶界面標記語言如大多數標記和編程語言一樣,依賴着子應用程序運行時來將標記代碼解釋和呈現為可以處理和植入所需形式的程序代碼。在基於XML的用戶界面標記語言中,則傾向於依賴網絡瀏覽器排版引擎作為運行時,大多數代碼被重新解釋為JavaScript交給排版引擎。這意味着JavaScript可以用於將用戶界面標記語言擴展到未被排版引擎當前功能所覆蓋的範圍。

用戶界面標記語言[編輯]

XFD[編輯]

XFD,表示XML Form Definition,是支撐STARLIMS英語STARLIMS產品 (http://www.starlims.com頁面存檔備份,存於網際網路檔案館)) 的用戶界面標記語言,由Abbott Informatics開發。STARLIMS產品具有運行時和設計時工具的整套生態系統,使用XFD語言運行和創建可視化表單。STARLIMS v10 is powered by an XFD runtime developed using Microsoft .NET Framework and hosted in Internet Explorer browser. STARLIMS v11 introduces an additional XFD engine based on a server-side transformation engine that transforms the XFD into HTML5 compatible data designed to run on any HTML5 compliant browser. XFD is programmable in JavaScript based language.

QML[編輯]

QML是一種跨平台標記語言,用於為移動設備和桌面設備創建有硬件加速OpenGL驅動的用戶界面。QML接口使用JavaScript語言操縱。QML是Qt Project英語Qt Project的一部分,,最初由諾基亞擁有,現在由Digia擁有。

MXML[編輯]

MXML是基於XML的用戶界面標記語言,由是Macromedia於2004年3月推出。它目前是開放源代碼 (http://opensource.adobe.com頁面存檔備份,存於網際網路檔案館)) Apache Flex SDK第四版的一部分。MXML文件通過Flex SDK編譯成Flash Swf,在網絡瀏覽器上通過Adobe Flash呈現,或者通過開源的Adobe AIR SDK作為獨立的跨平台應用程序。

UIML[編輯]

UIML英語UIML是用戶界面標記語言的最早開拓者。[來源請求]它是一個開源標準,其實現不局限於單一供應商。

XUL[編輯]

Mozilla基金會產品主要使用的界面語言是XUL。XUL文檔由Gecko引擎呈現,並也呈現XHTMLSVG文檔。它與許多現有標準和技術相結合,包括CSSJavaScriptDTDRDF

UsiXML[編輯]

UsiXML英語UsiXML (which stands for User Interface Extensible Markup Language) is a XML-compliant markup language that describes the UI for multiple contexts of use such as Character User Interfaces (CUIs), Graphical User Interfaces (GUIs), Auditory User Interfaces, and Multimodal User Interfaces. In other words, interactive applications with different types of interaction techniques, modalities of use, and computing platforms can be described in a way that preserves the design independently from peculiar characteristics of physical computing platform.

WTKX[編輯]

WTKX是一種基於XML的標記語言,用於構建Apache Pivot英語Apache Pivot應用程序。。儘管它最常用於定義應用程序用戶界面的結構,它也可以用來聲明性地構造任何類型的Java對象層次結構。

XAL[編輯]

eXtensible應用程序語言是Nexaweb's英語Nexaweb Enterprise Web 2.0套件的標記語言。開發人員可以使用這種語言來定義將作為Java客戶端或AJAX客戶端運行的應用程序。

SVG[編輯]

可縮放向量圖形(SVG)是一種用於圖像的標記語言,由W3C提議,可為Web和移動應用程序支持豐富圖形。雖然SVG不是用戶界面語言,但它包括矢量/光柵圖形、動畫、與DOM和CSS交互、嵌入式媒體、事件以及可腳本化的支持。如果組合使用這些功能,有可能製作出豐富的用戶界面。

SVG也可以疊加在另一個XML兼容的用戶界面標記語言上(如XULXForms),作為用戶界面的富圖形部分。

TUIX[編輯]

TUIX英語TUIX是一個基於XML的標記語言,用於定義Tribiq英語Tribiq CMS的用戶界面。開發人員可以定義界面的外觀及其相互作用。不同插件的TUIX文件在渲染之前被合併,便於修改現有接口和添加新功能。

XAML[編輯]

XAML是微軟.NET框架3.0及更高版本的建構用戶界面組件的一種標記系統。它的範圍比大多數用戶界面標記語言更有抱負,其程序邏輯和風格也被嵌入到了XAML文檔。在功能上,它可以被看作是XUL、SVG、CSS和JavaScript被組合到一種XML模式。

有些人[誰?]批評這個設計,因為許多標準(例如上文列出的標準)已經在做這些事。但是,預計將會開發一個可視化工具,開發人員甚至不需要了解底層標記。

I3ML[編輯]

I3ML英語I3ML is a proprietary thin client Application Delivery mechanism developed by CoKinetic Systems Corp頁面存檔備份,存於網際網路檔案館), with client support provided by a browser plugin that will render windows-like applications over an HTTP infrastructure with minimal bandwidth needs.

OpenLaszlo (LZX)[編輯]

OpenLaszlo英語OpenLaszlo is a runtime environment that comprises a runtime environment and an interface definition language (Laszlo XML - LZX). LZX is a declarative user interface language which defines the widgets, application layout and scripting elements (using JavaScript) to create your application. LZX is runtime agnostic with the currently supported runtime being within Macromedia/Adobe Flash. An experimental runtime called Laszlo "Legals" that will allow OpenLaszlo (LZX) applications run in multiple runtime environments, such as DHTML/AJAX.

HMVCUL[編輯]

分層模型視圖控制器用戶界面語言英語Hierarchical Model View Controller User Interface LanguageHMVCUL)是一種XML標記用戶界面語言,其支持創建和鏈接用於構建HMVC GUI應用程序的原子MVC三元組件。The associated runtime provides methods which enable configuration of properties, data binding and events of each of the MVC triad elements (widget, controller, model). The runtime accomplishes this by mapping XML elements defined in an HMVCUL file to objects inside the framework, attributes to properties or to events. Chaining is accomplished by following the tree structure described inside the HMVCUL file.

WasabiXML[編輯]

WasabiXML是一種XML標記語言,用於定義Wasabi英語Wasabi (software)驅動的應用程序的圖形界面。它最常見的用途是為Winamp製作Winamp皮膚。WasabiXML由Nullsoft為Winamp開發,但也可使用Wasabi SDK用於其他應用程序。

WasabiXML中的根元素是<WasabiXML>(對於Winamp皮膚來說,它是<WinampAbstractionLayer>。)<skininfo>元素顯示皮膚的信息。圖形界面依託<container>元素和,基礎可見的GUI元素為<layout>。下面是一個簡單的例子,展示有一個按鈕元素的圖形用戶界面

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<WinampAbstractionLayer version="1.2">
  <skininfo>
    <version>1</version>
    <name>mySkin</name>
    <comment>Ooo Lala</comment>
    <author>Some Person</author>
    <email>info@example.org</email>
    <homepage>http://www.example.org</homepage>
  </skininfo>
  <include file="xml/color-sys.xml"/> <!-- Include a file -->
  <container id="normal">
    <layout id="normal" desktopalpha="true">
      <button
        x="0" y="0"
        id="button.normal"
        image="mybutton.image"
        hoverimage="mybutton.himage"
        downimage="mybutton.dimage"
      />
    </layout>
  </container>
</WinampAbstractionLayer>

WasabiXML支持許多GUI元素,包括:

  • <button>
  • <text>
  • <vis>
  • <eqvis>
  • <layer>
  • <animatedlayer>
  • <groupdef>,與<group>配合使用

<groupdef> allows the developer to define a group of GUI objects which can be re-used anywhere in the skin. Wasabi also supports XUI's which are nothing but <groups> powered by a MAKI script allowing developers to create GUI components (widgets) of their own adding to modularity.

WasabiXML有一個XML名字空間「Wasabi::」定義了常見的GUI,而不需聲明它們的圖像路徑。

MARIA[編輯]

MARIA英語MARIA XML是一種通用、宣告式、多抽象層、基於XML的語言,用於普適環境中建模英語User Interface Modeling的交互式應用程序。

FXML[編輯]

FXML英語FXML是一種基於XML的語言,用於定義JavaFX應用程序的用戶界面。

其他[編輯]

現有框架中的其他標記語言有:

蘋果公司的Interface Builder .xib格式

其中一些被編譯為二進制形式。

航空電子領域中,ARINC 661英語ARINC 661標準規定了一個定義玻璃駕駛艙中用戶界面的二進制格式。

Borland VCL窗格(.dfm和.lfm)是描繪DelphiLazarus應用程序的窗口的文本文件。它們在最終的可執行文件中被編譯為二進制形成,並使用RTTI來操縱。

參見[編輯]

參考資料[編輯]