簡體   English   中英

如何使用Flex / Actionscript將圖像縮放到全屏

[英]How to scale an image to the full screen using Flex/Actionscript

我仍在努力通過Flashbuilder將Java / Eclipse中的應用程序構建轉換為Flex / Actionscript。 現在,我找不到如何實現覆蓋孔屏幕的圖像。 在我當前的應用中,我使用了相對布局和

    <ImageView
    android:id="@+id/img"
    android:scaleType="centerCrop"
    android:layout_width="fill_parent"
    android:layout_height="0dip"
    android:layout_above="@id/bottom"
    android:layout_below="@id/rubrik"
    />  

但我找不到如何在Flex視圖中對此進行定義。

看看這個SO問題

您需要修改Image spark標簽scaleMode屬性(如此處所述)。

<s:Image scaleMode="BitmapScaleMode.STRETCH" x="0" y="0" height="100%" width="100%" source="@Embed('assets/example.jpg')"/>

您可以玩BitmapScaleMode.STRETCH,BitmapScaleMode.ZOOM或BitmapScaleMode.LETTERBOX。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM