wix React-Native-Navigation V1 transparent background not working as expected - react-native

I'm trying to set the screen background to transparent using this navigator property:
screenBackgroundColor: 'transparent'
In addition, I changed the root view background color to Green in XCode like this:
self.window.backgroundColor = [UIColor greenColor];
I'm expecting to see the Green background without any interference . When running in Simulator I see a black rectangle with some opacity and a gradient toward the green color on the margins... (please see screenshot below) how to fix that? Maybe I'm missing some flag??
black rectangle instead of green background
I'm also using these other navigator style properties:
navBarTranslucent: true
navBarTransparent: true,
navBarNoBorder: true,
drawUnderNavBar: true
navBarTranslucent:true,
navBarBlur: false,
here I try to set the NavBar to Red background color and it still not working:
navbar background color red instead of transparent - still not working

Related

threejs setClearColor setting the opacity to 0 although the background is not there

I want to set the background color to blank, using the renderer.setClearColor (0xff0000, 0)[setClearColor ]:Changing three.js background to transparent or other color, setting the opacity to 0, although the background is not there, but on the page, there is almost no model
I have added some photo instructions,but the reputation is not enough, please check the link :https://github.com/shunzizhan/threejsDemo/wiki/three-scene
this.renderer = new WebGLRenderer({
antialias: true,
alpha: true
})
Set properties alpha true and then
this.renderer.setClearColor(0xffffff, 0)
it works

iOS7 what is the difference in all these color, "barTintColor, tintColor, backgroundColor, UITextAttributeTextColor"?

I am totally confused about all these color setting in navigationController in iOS7. Can someone tell me what exact difference are among all these things? I tried to figure out some of them, but not sure whether I am right.
Thank you!
self.navigationController.navigationBar.barTintColor=[UIColor redColor];//???
self.navigationController.navigationBar.backgroundColor=[UIColor greenColor];//???
self.navigationController.navigationBar.tintColor=[UIColor whiteColor];//the text colour of backButton of the navigationBar???
self.navigationController.navigationBar.titleTextAttributes = #{UITextAttributeTextColor:[UIColor blueColor]};//the text color of the title of the navigationBar
[self.navigationItem.rightBarButtonItem setTitleTextAttributes:#{UITextAttributeTextColor:[UIColor greyColor]} forState:UIControlStateNormal];//the text colour of the customised rightButton in the navigationBar
Here are the difference between above :
barTintColor : The tint color to apply to the navigation bar background.
backgroundColor : change the background color of navigationBar
tintColor : The tint color to apply to the navigation items and bar button items.
UITextAttributeTextColor : Key to the text color in a text attributes dictionary.The corresponding value is an instance of UIColor. Available in iOS 5.0 and later.Deprecated in iOS 7.0. It’s an easy fix. Just change UITextAttributeTextColor to NSForegroundColorAttributeName
Here is the more details : https://developer.apple.com/library/ios/documentation/uikit/reference/UINavigationBar_Class/Reference/UINavigationBar.html

pygtk scrolledwindow background color

I have the following code in my PyGTK application:
scroll = gtk.ScrolledWindow()
scroll.set_policy(gtk.POLICY_NEVER, gtk.POLICY_AUTOMATIC)
scroll.modify_bg(gtk.STATE_NORMAL,gtk.gdk.Color("#FFFFFF"))
scroll.add_with_viewport(self.movieView)
layout = gtk.VBox()
layout.pack_start(top,False,False)
layout.pack_start(scroll)
But the background of the scroll area still shows up gray, instead of white
Is this a known bug, or am I doing something wrong?

How to set background color of an image using draw2d?

I have drawn one rectangle by using RectangleFigure in draw2d. And I am able to
color the rectangle figure by calling rectangleFigure.setBackgroundColor.
Now the same way I want to color the Image also. For that I used ImageFigure in
draw2d and I gave the background color by calling ImageFigure.setBackgroundColor().
But it does not give any color for me. So How can I give the background color
to the image figure in draw2d?
RectangleFigure extends Shape which draws it's own background by default. ImageFigure directly extends Figure which will only draw the background if you set it as Opaque:
imageFigure.setOpaque(true);

QML:Transparency for an rectangle is not working

How to set transparency of an rectangle/screen.
I have Following code:
// main.cpp
void main(int argc, char*[] argv)
{
QApplication::setGraphicsSystem("raster");
QApplication app(argc, argv);
QDeclerativeView view;
view.setSource(QUrl::fromLocalFile("loaderTest.qml"));
view.setResizeMode(QDeclarativeView::SizeRootObjectToView);
view.showFullScreen();
//QRegion mask(10, 10, 100, 100);
//view.setMask();
view.show();
app.exec();
}
And QML file is:
//loaderTest.qml
Rectangle
{
id: mainRectangle
width: 1000
height: 700
color: "transparent"
//color: "#00000000"
Image
{
id: image1;
width: 348;
height: 155;
anchors.horizontalCenter: parent.horizontalCenter;
anchors.verticalCenter: parent.verticalCenter;
source: "test.png"
}
Loader
{
id: mainLoader
anchors.fill: parent;
source: "";
focus: true;
}
}
I have one loader and one image in this screen and background color is transparent.
When i run this application it should display transparent background with image in the center (as i have not set loader source).
but what i am getting is image in center with white background filled in the screen, I don’t know who is filling in this white background color as i have mentioned transparent color as background.
I am using QT.4.7.0 and Linux.
I have two planes on my target system one is Video plane and another is graphics plane, when i run GUI with transparent background (set transparency at video place) it should display video on Video place in above example it is showing background as white, as it should have displayed video playing on Video plane.
By default the QDeclarativeView paints a background. Maybe that's the problem in your case.
From http://doc.qt.nokia.com/4.7/qdeclarativeperformance.html
You can also prevent QDeclarativeView from painting its window background if you will provide the background of your application using QML, e.g.
QDeclarativeView window;
window.setAttribute(Qt::WA_OpaquePaintEvent);
window.setAttribute(Qt::WA_NoSystemBackground);
window.viewport()->setAttribute(Qt::WA_OpaquePaintEvent);
window.viewport()->setAttribute(Qt::WA_NoSystemBackground);
My first guess is that the background is white and your rectangle is indeed fully transparent.
What type is LoaderScreen, I guess it is some sort of QDecalarativeView, please forgive any technical misses have not coded Qt/QML for almost a year now. As I remember it the default background of the view was white and what kind of transparency are you hoping to achive anyways?
If you only set a background-color on a QPushButton, the background may not appear unless you set the border property to some value. This is because, by default, the QPushButton draws a native border which completely overlaps the background-color.
This might show a black rectangular box around QPushButton. You will face this issue especially on Linux machines. In order to avoid this you can set the border property to none
widget->setStyleSheet("border:none");