w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Colors in Holo light/dark
Most of the colors can be found in the colors.xml file which can be found in android-sdk-windowsplatformsandroid-18data esvalues Edit: the list seperator you are asking about is actually a drawable, you can find the style here <style name="Widget.Holo.Light.TextView.ListSeparator" parent="Widget.TextView.ListSeparator"> <item name="android:background">@android:drawable/list_section_divider_holo_light</item> <item name="android:textAllCaps">true</item> </style> you can find that in the drawables folder

Categories : Android

Holo Light with Dark Actionbar showing Holo Dark copy and paste icons
I have this problem with Theme.AppCompat.Light.DarkActionBar theme and I think it's a bug. I tried to change the background in my style with the following (you can get the drawables from http://jgilfelt.github.io/android-actionbarstylegenerator/): <!-- styles.xml --> <style name="Theme.MyThemeLightBase" parent="@style/Theme.AppCompat.Light.DarkActionBar"> <item name="actionModeBackground">@drawable/cab_background_top</item> <item name="android:actionModeBackground">@drawable/cab_background_top</item> </style> And with this: <!-- styles.xml --> <style name="Theme.MyThemeLightBase" parent="@style/Theme.AppCompat.Light.DarkActionBar"> <item name="actionModeStyle">@style/my_action_mode_style</item> <item n

Categories : Java

Editing Holo Light with Dark Action Bar
You can create a custom style which you can add to your theme. <?xml version="1.0" encoding="utf-8"?> <resources> <!-- the theme applied to the application or activity --> <style name="MyActivityTheme" parent="@android:style/Theme.Holo.Light"> <item name="android:actionBarStyle">@style/MyActionBar</item> <!-- other activity and action bar styles here --> </style> <!-- style for the action bar backgrounds --> <style name="MyActionBar" parent="@android:style/Widget.Holo.Light.ActionBar"> <!-- Use a color attribute defined in colors.xml --> <item name="android:background">@color/orange</item> <!-- Or use a regular color code (This is orange)--> <item name="android:background">#F

Categories : Android

How to get dark action bar for Theme.Holo.Light.DialogWhenLarge?
it looks like you just need to make a copy of DialogWhenLarge in values/themes: <style name="PopupActivity" parent="@android:style/Theme.Holo.Light.DarkActionBar"> </style> in values-large/themes: <style name="PopupActivity" parent="@android:style/Theme.Holo.Light.DialogWhenLarge"> </style> note you could also use Theme.Holo.Light.Dialog.MinWidth as the parent for your large version but if things were added to the DialogWhenLarge theme you would miss out on those. that should work but I dont have anything setup to test it.

Categories : Android

Strange lighting effect in direct3d switches dark and light
I needed to add some texture stages before actually drawing the object. device->SetTextureStageState (0, D3DTSS_COLOROP, D3DTOP_SELECTARG1); device->SetTextureStageState (0, D3DTSS_COLORARG1, D3DTA_CURRENT); device->SetTextureStageState (0, D3DTSS_ALPHAOP, D3DTOP_SELECTARG1); device->SetTextureStageState (0, D3DTSS_ALPHAARG1, D3DTA_CURRENT); device->SetTextureStageState (1, D3DTSS_COLOROP, D3DTOP_DISABLE); device->SetTextureStageState (1, D3DTSS_ALPHAOP, D3DTOP_DISABLE);

Categories : C++

Using parent="@android:style/Widget.Holo.Light.ActionBar" brings the Dark ActionBar
This might be helpful for you: <style name="AppTheme" parent="@android:style/Theme.Holo.Light"> <item name="android:actionBarStyle">@style/AppTheme.ActionBar</item> <item name="android:textAllCaps">false</item> </style> <style name="AppTheme.ActionBar" parent="@android:style/Widget.Holo.Light.ActionBar"> <item name="android:background">@drawable/actionbar_background</item> <item name="android:titleTextStyle">@style/AppTheme.ActionBar.Text</item> <item name="android:textColor">@color/white</item> </style> In <item name="android:background">@drawable/actionbar_background</item> you can declare the drawable xml if you want the gradients or you can directly declare the color

Categories : Android

How to change theme of TabHost from Holo.Light to Dark theme
This will work: //Changing the tabs background color and text color on the tabs for(int i=0;i<tabs.getTabWidget().getChildCount();i++) { tabs.getTabWidget().getChildAt(i).setBackgroundColor(Color.BLACK); TextView tv = (TextView) tabs.getTabWidget().getChildAt(i).findViewById(android.R.id.title); tv.setTextColor(Color.parseColor("#ffffff")); } And for the indicator, have a layout like this beneath tabwidget <LinearLayout android:id="@+id/tab_indicator" android:layout_width="fill_parent" android:layout_height="5dp" android:background="#bdbdbd" > <LinearLayout android:id="@+id/tab_indicator_left" android:layout_width="wrap_content" andro

Categories : Android

Finding exact HSV values of colors
Use a color picker web-site to check out the hue values of them. http://www.color-hex.com/color/eca314 http://www.color-hex.com/color/923ca7 Note that you need to transform the hue angle (0-360) between (0-255) range. Use inranges function for both colors and add the images: cvInRangeS(hsvframe,cvScalar(20, 0, 0), cvScalar(30, 255, 255),threshorange); cvInRangeS(hsvframe,cvScalar(200, 0, 0), cvScalar(210, 255, 255),threshpurple); cvOr(threshorange, threshpurple, threshy);

Categories : Opencv

Trying to set "background-color=dark" but error is : E492: Not an editor command: background=dark
You want set background=dark The other is an ill formed command. You can put any ex command in your vimrc by dropping the :. So instead of typing :set background=dark on the command line you put set background=dark in your vimrc. However this command should not be in your vimrc. It should be set by your colorscheme. The first part of your question seems to be how do I set the colorscheme desert from the command line. Well the command is :colorscheme desert. So if you want to restore the desert colorscheme everytime you load vim you can put colorscheme desert in your vimrc. (/root/.vimrc in this case)

Categories : Vim

How to use android light level sensor to detect light wavelength?
Taken from this answer (by Noah Witherspoon): The camera chip converts a given wavelength of light into a signal by overlaying colored filters—red, green, and blue—onto subpixel sensors that are sensitive to a broad range of wavelengths. As such, the camera isn’t actually sensing the wavelength; it’s sensing the relative strength of the light at a couple of key peak wavelengths. As described in this answer, you can approximate the peak wavelength of a given RGB color by converting it to HSV (hue/saturation/value) and then interpolate from violet to red wavelengths by the hue component. The answer he is referring to is this one: How to get the wavelength of a pixel using RGB?

Categories : Android

android light sensor - detect significant light changes
try the below code :- import android.hardware.Sensor; import android.hardware.SensorEvent; import android.hardware.SensorEventListener; import android.hardware.SensorManager; import android.os.Bundle; import android.app.Activity; import android.widget.TextView; public class MainActivity extends Activity { TextView textLIGHT_available, textLIGHT_reading; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); textLIGHT_available = (TextView)findViewById(R.id.LIGHT_available); textLIGHT_reading = (TextView)findViewById(R.id.LIGHT_reading); SensorManager mySensorManager = (SensorManager)getSystemService(SENSOR_SERVICE); Sensor LightSenso

Categories : Android

Show Light AlertDialog using Theme.Light.NoTitleBar
You have to use an AlertDialog Builder. With it you can set a style to your Dialog. Look the following example: http://pastebin.com/07wyX0V3 <style name="popup_theme" parent="@android:style/Theme.Light"> <item name="android:windowBackground">@color/back_color</item> <item name="android:colorBackground">@color/back_color</item> </style>

Categories : Java

Navigation bar/menu not showing in customised colors with Safari (Correct colors in other browsers)
nav ul { margin: 80px 0 20px 0; padding: 0em; float: left; list-style: none; background: #1A1A1A; background: rgba(26,26,26,.2); -moz-border-radius: .5em; -webkit-border-radius: .5em; border-radius: .5em; -moz-box-shadow: 0 1px 0 rgba(255,255,255,.2), 0 2px 1px rgba(0,0,0,.8) inset; -webkit-box-shadow: 0 1px 0 rgba(26,26,26,.2), 0 2px 1px rgba(0,0,0,.8) inset; box-shadow: 0 1px 0 rgba(26,26,26,.2), 0 2px 1px rgba(0,0,0,.8) inset; } You've got background twice once as hex the other as rgba, I think you only need one.

Categories : Javascript

Weird colors in background of UIImage when trying to replace all white colors
Using a different code I slipped in my loop and it no longer showed the random background static: -(UIImage *)replaceWhiteWith{ NSString *str = [[NSUserDefaults standardUserDefaults] objectForKey:@"color"]; UIColor *color = [NSString colorFromNSString:str]; CGFloat red = 0.0, green = 0.0, blue = 0.0, alpha =0.0; [color getRed:&red green:&green blue:&blue alpha:&alpha]; CGImageRef inImage = self.CGImage; CFDataRef ref = CGDataProviderCopyData(CGImageGetDataProvider(inImage)); UInt8 * buf = (UInt8 *) CFDataGetBytePtr(ref); int length = CFDataGetLength(ref); for(int i=0; i<length; i+=4) { int r = buf[i]; int g = buf[i+1]; int b = buf[i+2]; if(r == 255 && g == 255 && b == 255){

Categories : IOS

Add alternating row colors with column grouping colors-is it possible?
Since your rows are alternating light/dark, you could take advantage of an alpha transparent background color: http://cssdeck.com/labs/6rgab657 <table> <colgroup class="a" span="4" /> <colgroup class="b" span="4" /> <colgroup class="c" span="4" /> <colgroup class="d" span="4" /> <tr> <td>A</td> <td>A</td> <td>A</td> <td>A</td> <td>B</td> <td>B</td> <td>B</td> <td>B</td> <td>C</td> <td>C</td> <td>C</td> <td>C</td> <td>D</td> <td>D</td> <td>D</td> <td>D</td> </tr> <tr> &l

Categories : Jquery

Use Theme.Light Datepicker on Theme.Holo.Light
Have you tried something like <DatePicker ... style="@android:style/Widget.DatePicker"/> ? Holo uses @android:style/Widget.Holo.DatePicker while @android:style/Widget.DatePicker is the one you need to use. Links: Style list Style list's source code Update: It seems that DatePicker is built with 3 NumberPickers. My answer is correct, but it is incomplete. The best approach I found to solve your problem was to recreate ans make your own DatePicker (copypaste from source code) and give style to the DatePicker AND the 3 NumberPickers inside. Link of the Layout on GitHub: DatePicker Layout

Categories : Android

Custom theme for a dark actionbar / tab bar
this link helped me http://jgilfelt.github.io/android-actionbarstylegenerator/ @style/Widget.Sherlock.Light.ActionBar.Solid.Inverse did the trick

Categories : Android

Android full screen app too dark
you can set a custom theme for your app in manifest as white background. Then if wont have any default behaviour. Currently it may be picking default android theme.. <style name="CustomTheme" parent="android:Theme.Light"> <item name="android:windowBackground">@color/custom_theme_color</item> <item name="android:colorBackground">@color/custom_theme_color</item> </style>

Categories : Android

Facebook Sdk for ios publish -dark screen
You can do like this, while opening the session specify permission to publish post NSArray *permissions = [[NSArray alloc] initWithObjects:@"publish_actions",@"publish_stream",nil]; //permissions return [FBSession openActiveSessionWithPermissions:permissions allowLoginUI:allowLoginUI completionHandler:^(FBSession *session,FBSessionState state,NSError *error) and whenever you want to publish, do like this NSMutableDictionary *params = [[NSMutableDictionary alloc]initWithObjectsAndKeys:TextView.text, @"message",nil]; // set the formats if([FBSession.activeSession.permissions indexOfObject:@"publish_actions"] != NSNotFound) { [FBRequestConnection startWithGraphPath:@"me/feed" parameters:params HTTPMethod:@"POST" completionHandler:^(FBRequestConnection *connection, id res

Categories : IOS

iOS : AVFoundation Image Capture Dark
I had the same issue on an iOS 7 5th gen ipod touch, but not on a 4th gen ipod touch with iOS 6.1. I found that the fix is to show a preview of the camera: // Setup camera preview image AVCaptureVideoPreviewLayer *previewLayer = [[AVCaptureVideoPreviewLayer alloc] initWithSession:_captureSession]; [_previewImage.layer addSublayer:previewLayer]; As instructed at https://developer.apple.com/library/ios/documentation/AudioVideo/Conceptual/AVFoundationPG/Articles/04_MediaCapture.html#//apple_ref/doc/uid/TP40010188-CH5-SW22 Note: I did not investigate accomplishing this without a preview

Categories : IOS

Detect bright and dark images
OK, after looking at it again, I notice that the comparison at the end of the function looks backwards (based on the name of the variable "darkProcent"). I think the comparison operator should be >=, not <=. That got me the answers I was expecting with my test images.

Categories : C#

How can I force my Widgets to use a dark theme?
To solve this (the easy way) you should use Theme.Holo. And Change the actionbar to Theme.Holo.Light. extend theme: <style name="MyTheme.Dark" parent="android:Theme.Holo.Light.ActionBar"></style> use getActionBar().getThemedContext() as the context for inflating your views.

Categories : Android

ActionBar has correct colors in Android 4.2, wrong colors in Android 2.3
As per the official docs, you need to also declare the attributes without the android: namespace. In your case, those attributes are only getting applied to the native implementation.

Categories : Android

Dark Transparent Layer on Inactive Form
The Form has an opacity property though: Form.Opacity Just set this to 0.25 On the Deactivate Event and 1 on the Activate Event

Categories : Vb.Net

Customized Google maps on iOS to a dark color
The pricing for MapBox is here: http://www.mapbox.com/plans/ And info on their iOS SDK is here: http://www.mapbox.com/tour/#section-ios-sdk There is a feature request to add styling support to the google maps SDK here: https://code.google.com/p/gmaps-api-issues/issues/detail?id=4968

Categories : IOS

OpenGL Textures form SDLSurface goes too dark
You probably have some state set elsewhere in your code that is still enabled when you want it disabled for drawing this quad. Try putting the following after glBindTexture(GL_TEXTURE_2D, _texture); in your draw code (it's important that it's done in the draw method and not the createTextureFromSurface method): glDisable(GL_BLEND); glDisable(GL_LIGHTING); glTexEnvi( GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE ) glColor3f(1.0f, 1.0f, 1.0f); If this works you can comment them out one at a time to figure out which state was causing your problem. Any state you disable for drawing this quad will need re-enabled when drawing the object that required it.

Categories : C++

Download for Holo Dark nav drawer icon
Look here: http://developer.android.com/training/implementing-navigation/nav-drawer.html It should be also in other places soon.

Categories : Android

Draw UIlabel With dark shadow color
I hope my suggestions will be help full to you , self.averageLabel.bordercolor =[UIColor whitecolor]; self.averageLabel.layer.borderwidth=3.0; Or once you refer this link provided below. How do I make UILabel display outlined text?

Categories : Misc

Is there a dark theme that supports Clojure on intellij?
Have you tried IntelliJ Colors Solarized theme? But why the Dracula Theme isn't good for Clojure? Personally I use VIM in JellyBeans theme for Clojure development.

Categories : Clojure

Drawing repetitively one canvas without that edges become dark
As long as the image has an alpha-channel you cannot avoid this when re-painting it over and over without some mechanism to reset the alpha values drawn. The reason for this is that the alpha-value for that pixel will accumulate so when you draw a non-opaque edge (or anti-aliased edge) on top of each other the value for the alpha channel will be added to the value already drawn resulting in that the edge will be more and more visible. There are fortunately a couple of ways to avoid this: A) If you want to keep the alpha-channel in the image use clearRect before drawing the image. context.clearRect(0, 0, img.width, img.height); context.drawImage(img, 0, 0); This will clear the canvas and the alpha channel. ONLINE DEMO B) If alpha channel is not important save out the image without

Categories : HTML

DialogPreference textview is dark on android 2.3.5, works on >4.0
Have a look at your styles.xml in your value folder! Put anything else in the parent of your app theme... That should fix the "dark" theme issue ;) ex: .Light theme After that, you can change the styles.xml of the value-v11 folder & value-v14 folder to holo, which will take Holo theme in consideration when the API level support it!

Categories : Android

Custom Font color (Dark Navy Blue)
Something like this: [UIColor colorWithRed: 0f green:0f blue:0.5f alpha:1.0] should be closer. If you want other colors, use a color chart like this one on Wikipedia, and just convert the percentages to values between 0 and 1 (e.g. 30% = 0.3)

Categories : Misc

How to style nav drop down menus with dark gradient instead of white?
It's a little hard to understand the question, but I think that if I'm on the same page with you, you want the nav's dropdown to be with any other color instead of white. I would definitively suggest here that when something doesn't ship with bootstrap it doesn't mean you can't extend it with your own stylesheet. Make sure you add your styles at the bottom of all the other styles (preferably in a new stylesheet so you don't modify the stock bootstrap files). Here's a Fiddle of the dropdown with black instead of white. jsFiddle: Demo Notice how I added .mainNav to the <ul class="nav nav-tabs"> in order to have a specific hook to this navigation in case you don't want your styles to cascade to all the drop down's on your site. The main thing here is to remember that just because

Categories : CSS

ImageMagick RGB to CMYK conversion results in very dark images
I had the same problem, ImageMagick 6.7.7-7 works fine but ImageMagick 6.8.6-9 doesn't. I founded a issue called ImageMagick 6.7.6.4 produces all black images due to -colorspace RGB argument on GitHub and all works fine now (I don't have this version but it works). Summarizing: The solution is change RGB to sRGB. Sorry for my english.

Categories : Misc

how to make the screen dark and start a progressBar in android?
If your HTTPClient is in an Asynctask, put your progress bar visibility GONE in the 'onPostExecute' to dim the screen, you need to show an alert dialog/ dialog fragment and set your custom layout with the progress bar, then dismiss it when the loading as finished. that will automatically dim the screen.

Categories : Java

Generate n colors between two colors
You have to blend each color channel (red, green and blue) seperately like this: Color x,y; //set by you float blending;//set by you float inverse_blending = 1 - blending; float red = x.getRed() * blending + y.getRed() * inverse_blending; float green = x.getGreen() * blending + y.getGreen() * inverse_blending; float blue = x.getBlue() * blending + y.getBlue() * inverse_blending; //note that if i pass float values they have to be in the range of 0.0-1.0 //and not in 0-255 like the ones i get returned by the getters. Color blended = new Color (red / 255, green / 255, blue / 255); So far for the color example. Generally if you want a linear interpolation between two values you have to do the following: var firstValue; var secondValue; var interpolation; var inter

Categories : Java

VS2012 Scroll Bar "Full Mode" Bright in Dark Theme
Reinstalling the Productivity Power Tools with Dark Theme active (including the restarts) and then going back and forth between Dark and Bright Theme solved the issue. However, there is a already a bug report filed on MS Connect, so chances are this will be fixed in a future update of the Productivity Power Tools.

Categories : Visual Studio 2012

|[Solved] Visual Studio 2012 Dark Theme Issue
Edit: The issue is that the "Item foreground" and "Item background" settings gets set to something OTHER than "Default". The fix is to go to Tools > Options > Environment - Fonts and Colors and setting the said properties to "Default". Well, I fiddled with the Tools > Options > Environment - Fonts and Colors options for a while and managed to restore order. I'm not sure what messed it up initially!

Categories : Visual Studio 2012

How to get some stlyed item from Holo Dark theme to older android versions?
You need HoloEverywhere. Althought If your need is only change background of Editext or any views, you should copy them from newer sdk's sdk/platforms/version/data/res directory and use them into your project .

Categories : Android

AVFoundation adjusting white balance while focus is close up and background (out-of-focus) is dark
The answer to this question, for those who run across the same issue, is to use a CALayer for an exposeBox and another CALayer for a focusBox. That appeared to do the trick. Of course, I would still like to hear of solutions from others and I'm still curious about controlling the aperture. Thank you.

Categories : Objective C



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.