我有一个具有背景的Windows窗体应用程序.在其中,我有一个透明背景的flowlayoutpanel.当我滚动时,会发生以下情况:

我也看到一些闪烁.我已经尝试了所有的双缓冲业务,但它不起作用.
有什么建议?
I'm trying to make my tabBar transparent, I've searched but all I found was articles resulting in partly and not fully transparent tabBars and some were for IOS 5, etc.
I would like to accomplish this as seen in Sketch 3:

What's the easiest way to accomplish this?
I thought of doing this:
// Make the tabBar transparent
self.tabBarController.tabBar.backgroundColor = [UIColor clearColor];
self.tabBarController.tabBar.translucent = YES;
Run Code Online (Sandbox Code Playgroud)
but that result wasn't exactly perfect:

Really appreciate help!:)
Sincerely, Erik
Update
// Make the …Run Code Online (Sandbox Code Playgroud) 我正在寻找一个透明的动画加载图标; 然而(我知道我很懒)我不想自己做.如果这不是这篇文章的正确论坛,请原谅我,过去我刚刚有这么多运气.有谁知道我在哪里可以找到其中之一....它需要非常小(图标大小).
我想让Gtk +窗口的背景透明,以便只有窗口中的窗口小部件可见.我找到了一些教程:
http://mikehearn.wordpress.com/2006/03/26/gtk-windows-with-alpha-channels/
http://macslow.thepimp.net/?p=26
但他们似乎都在听"揭露"事件,然后委托开罗进行渲染.这意味着不会渲染添加到窗口的其他窗口小部件(例如,我也尝试向窗口添加按钮).
我看到GtkWidget上有一个方法modify-bg:http://library.gnome.org/devel/gtk/stable/GtkWidget.html#gtk-widget-modify-bg
但是,GdkColor似乎不接受透明度参数:http://library.gnome.org/devel/gdk/stable/gdk-Colormaps-and-Colors.html
我也尝试了GtkWindow.set_opacity方法,但这也设置了窗口内容的不透明度,这不是我想要的.
我很感激任何人都可以提供的任何指导.
是否可以显示具有可控alpha的PyGame表面?我想采用具有自己的每像素alpha的表面,并以不同的半透明度显示它,而不影响表面数据并保持透明度完好无损,即表面上的物体将保持其形状但其"内容"变得或多或少半透明.
换句话说,我想将来自源图像的每像素alpha与运行时计算的每表面alpha组合.
我目前有一个表格,除了一个之外,还有所有想要的效果.目前的形式由顶部的menustrip组成,下面有一个面板,其中包含标签和图片框.当表单启动时,menustrip不可见,只有当用户按下"Alt"按钮并且以相同的方式消失时,它才会变得可见.
面板将具有透明背景(.PNG)的背景图像.这个图像将成为表单的主要布局,因为我将borderstyle设置为none.现在的问题是表单在面板下方仍然具有白色/浅灰色背景.
现在我的问题是如何使表单透明,以便面板上的图像成为主要布局,而不仅仅是图像下面的图像背面颜色.我不想使用Opacity属性,因为我希望面板100%可见.
我有一个自定义图像背景,填充ListView后面的整个屏幕.
ListView有一个包含一些数据的标题,然后是一个透明的10dp边距(允许我们看到一点背景图像),然后是一些更多的数据.在这个标题下面,在ListView的"主体"中,我需要让ListView的背景一直填充到屏幕的底部,即使其中的项目不是一直到底部.
如果我设置ListView的背景,那么即使只有几个项目(或根本没有项目),我也会得到所需的效果,总是填充到屏幕的底部.但这也掩盖了标题中的10dp透明分隔符,因此我无法再通过标题看到自定义背景.
可有人请点我下来得到正确的路径都在屏幕的填充,同时保持头部里面的透明分隔?
有人提到我可能需要创建"假"项单元格,可用于创建ListView背景的错觉,而不会影响标题的透明分隔符.但是,我希望在可能的情况下找到一个更简单的解决方案..或者如果这是最好的解决方案,看看有人能给我一些关于如何以最有效的方式实现这一目标的指示.
谢谢!
编辑:
这是我如何定义标题,虽然我认为这个问题与ListView有关,而不是我通过addHeaderView()添加到ListView的标题.
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:background="@android:color/transparent" android:orientation="vertical">
<include android:id="@+view_list_header/headertop"
layout="@layout/view_list_item"/>
**<LinearLayout android:id="@+view_list_header/ll_transparent_filler"
android:layout_width="fill_parent" android:layout_height="10dp"/>**
<RelativeLayout android:id="@+view_list_header/sort" android:layout_width="fill_parent" android:layout_height="wrap_content">
<TextView.../> <ImageView.../> <TextView.../>
</RelativeLayout>
</RelativeLayout>
Run Code Online (Sandbox Code Playgroud)
所以,我尝试了各种方法来创建10dp填充程序,目前我正在使用"空"10dp LinearLayout,以便我可以获取对它的引用并在我想要时将其可见性设置为GONE(我不做在我讨论的情况下)
我正在设置ListView的背景,如下所示:listView.setBackgroundResource(resource).
再次,当我将背景设置为此ListView时,我得到所需的背景行为始终填满整个屏幕,即使我已添加到列表中的项目数量(顺便说一下,所有项目都使用与我相同的背景资源)设置为ListView)不足以填满屏幕.但是当我这样做时,标题中的10dp"透明边距"是不可见的,因为在它后面,ListViews背景阻止了底层视图被看到.
我假设发生这种情况是因为ListView的背景也落后于页眉和页脚视图.
关键是,有很多方法可以在元素之间创建10dp"透明边距",以允许底层视图显示.我的问题在于为ListView"body"(即不是页眉/页脚)创建一个总是填满屏幕的背景,即使列表部分填充或为空,同时保留标题中的透明度以便我仍然可以看到ListView"后面"的视图.
我试图在我的应用程序中显示透明的GIF图像,但没有成功.我可以在ImageView中下载并显示图标,但是使用白色背景而不是透明.
我已经尝试过这些没有成功的解决方案: 以编程方式将GIF转换为PNG
有没有人想出如何透明地显示GIF图像?我使用的是Android 18 SDK.
我对RenderScript ScriptIntrinsic Blur有一些问题 - 在某些设备上它不会模糊整个图像.我缩小输入图像的尺寸并确保宽度是4的倍数(因为它是由Roman Nurik建议的:https://plus.google.com/+RomanNurik/posts/TLkVQC3M6jW)
@SuppressLint("NewApi")
private Bitmap blurRenderScript(Bitmap smallBitmap) {
Bitmap output = Bitmap.createBitmap(smallBitmap.getWidth(), smallBitmap.getHeight(), smallBitmap.getConfig());
RenderScript rs = RenderScript.create(getContext());
ScriptIntrinsicBlur script = ScriptIntrinsicBlur.create(rs, Element.U8_4(rs));
Allocation inAlloc = Allocation.createFromBitmap(rs, smallBitmap, Allocation.MipmapControl.MIPMAP_NONE, Allocation.USAGE_GRAPHICS_TEXTURE);
Allocation outAlloc = Allocation.createFromBitmap(rs, output);
script.setRadius(BLUR_RADIUS);
script.setInput(inAlloc);
script.forEach(outAlloc);
outAlloc.copyTo(output);
rs.destroy();
MutableBitmap.delete(smallBitmap);
return output;
}
Run Code Online (Sandbox Code Playgroud)
它正在开发Nexus 4:


但在Galaxy S4上,右侧有透明边缘:


我希望你能看出我的意思 - 如果你用gimp打开图片,或者你可以更好地看到它.它不依赖于图片大小.我也尝试了越来越大的图像,结果总是一样的.例如,它也发生在Nexus 7 2012上.此外,透明工件有时位于bottem或左边缘.在此先感谢您的帮助!
Nexus 4:4.4.2/Build Number KOT49H Galaxy S4:4.2.2/Build Number JDQ39.I9505XXUDMGG
我想在我的应用中显示消息通知.在以前的Android版本中,一切都很好,但在Lollipop中,通知背景是白色的.我将此XML代码用于我的通知布局layout_message_notification.xml:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/layout_messageNotification"
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/transparent">
<LinearLayout
android:layout_width="0dp"
android:layout_weight=".2"
android:layout_height="wrap_content"
android:background="@android:color/transparent">
<ImageView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:scaleType="fitCenter"
android:src="@drawable/message_icon"/>
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_weight=".8"
android:layout_height="wrap_content"
android:background="@android:color/transparent">
<TextView
android:id="@+id/textView_notification_title"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:gravity="right|center_vertical"
android:layout_margin="15dp"/>
</LinearLayout>
</LinearLayout>
Run Code Online (Sandbox Code Playgroud)
我在棒棒糖中的通知显示如下:

如何将通知背景设置为暗或透明,就像以前的Android版本一样?
notifications android background transparent android-5.0-lollipop