Search Results

Search found 4481 results on 180 pages for 'black rez'.

Page 88/180 | < Previous Page | 84 85 86 87 88 89 90 91 92 93 94 95  | Next Page >

  • plotting stem with a continuous line

    - by Abruzzo Forte e Gentile
    Hi All I need to plot a stem plot of my signal using python and matplotlib. I saw the example and the code but the line connecting the black big dot and the x-axis is not a continous line. Do you know whether is possible and how to get a straight line instead? Thank you very much AFG #!/usr/bin/env python from pylab import * x = linspace(0.1, 2*pi, 10) markerline, stemlines, baseline = stem(x, cos(x), '-.') setp(markerline, 'markerfacecolor', 'b') setp(baseline, 'color','r', 'linewidth', 2) show()

    Read the article

  • Push SVG String into Dom?

    - by Colin
    I have a javascript variable that basically looks like this: my_svg_image = '<circle cx="227.58331298828125" cy="102" r="3" style="fill:black;stroke-width:0" />'; It was loaded from my database. Is there a way I can parse that string and add it to the DOM with Javascript? I have svgweb set up, but don't see how I can get it to parse this string. Are there other libraries that might help?

    Read the article

  • Multiple Regex on String

    - by George
    How can I apply multiple regexs to a single string? For instance, a user inputs the following into a text area: red bird blue cat black dog and I want to replace each carriage return with a comma and each space with an underscore so the final string reads as red_bird,blue_cat,black_dog. I've tried variations in syntax along the lines of the following so far: function formatTextArea() { var textString = document.getElementById('userinput').value; var formatText = textString.replace( new RegExp( "\\n", "g" ),",", new RegExp( "\\s", "g"),"_"); alert(formatText); }

    Read the article

  • Can I specify when my video shall start on html?

    - by zeina
    I want my video to show a specified image while embedding it on html basically I'm doing the following: <embed src="video.m4v" width="520" height="456" autoplay="false" controller="true" type="video/quicktime" scale="tofit" pluginspage="http://www.apple.com/quicktime/download/" bgcolor="black"> </embed> Is there a specific parameter that I can add that says when the video shall start?

    Read the article

  • Thread class closing from other Class (Activity) with protected void onStop() Android

    - by user1761337
    I have a Problem with Closing the Thread. I will Closing the Thread with onStop,onPause and onDestroy. This is my Source in the Activity Class: @Override protected void onStop(){ super.onStop(); finish(); } @Override protected void onPause() { super.onPause(); finish(); } @Override public void onDestroy() { this.mWakeLock.release(); super.onDestroy(); } And the Thread Class: public class GameThread extends Thread { private SurfaceHolder mSurfaceHolder; private Handler mHandler; private Context mContext; private Paint mLinePaint; private Paint blackPaint; //for consistent rendering private long sleepTime; //amount of time to sleep for (in milliseconds) private long delay=1000/30; //state of game (Running or Paused). int state = 1; public final static int RUNNING = 1; public final static int PAUSED = 2; public final static int STOPED = 3; GameSurface gEngine; public GameThread(SurfaceHolder surfaceHolder, Context context, Handler handler,GameSurface gEngineS){ //data about the screen mSurfaceHolder = surfaceHolder; mHandler = handler; mContext = context; gEngine=gEngineS; } //This is the most important part of the code. It is invoked when the call to start() is //made from the SurfaceView class. It loops continuously until the game is finished or //the application is suspended. private long beforeTime; @Override public void run() { //UPDATE while (state==RUNNING) { Log.d("State","Thread is runnig"); //time before update beforeTime = System.nanoTime(); //This is where we update the game engine gEngine.Update(); //DRAW Canvas c = null; try { //lock canvas so nothing else can use it c = mSurfaceHolder.lockCanvas(null); synchronized (mSurfaceHolder) { //clear the screen with the black painter. //reset the canvas c.drawColor(Color.BLACK); //This is where we draw the game engine. gEngine.doDraw(c); } } finally { // do this in a finally so that if an exception is thrown // during the above, we don't leave the Surface in an // inconsistent state if (c != null) { mSurfaceHolder.unlockCanvasAndPost(c); } } this.sleepTime = delay-((System.nanoTime()-beforeTime)/1000000L); try { //actual sleep code if(sleepTime>0){ this.sleep(sleepTime); } } catch (InterruptedException ex) { Logger.getLogger(GameThread.class.getName()).log(Level.SEVERE, null, ex); } while (state==PAUSED){ Log.d("State","Thread is pausing"); try { this.sleep(1000); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } }} How i can close the Thread from Activity Class??

    Read the article

  • polymorphism alternative for MySQL stored procedures

    - by zombiegx
    I'm porting some stored procedures from Informix to MySQL, but I have two stored procedures on Informix that have same name and different parameters. In MySQL, I can't create two SP with the same name, and also can't create a SP with default values in parameters. so, do someone out there know any hackery or black magic that may help me solve this problem? thanks.

    Read the article

  • App rejected due to "iPhone Apps must also run on iPad without modification, at iPhone resolution, and at 2X iPhone 3GS resolution"

    - by sunny
    My app got rejected by the apple because of the reason "iPhone Apps must also run on iPad without modification, at iPhone resolution, and at 2X iPhone 3GS resolution".Apple suggested that "to support the iPad 3GS 2X, and this issue is usually resolved through settings in "compatibility" mode. "no black bar's or borders"".So,my question is how to set and run the app in compatibility mode.Any one having this issue please help on this issue.I have no idea to go forward. Please any suggestions and help thanks in advance.

    Read the article

  • Show information over image on rollover

    - by Chris
    I want to be able to show information (HTML basically) over an image when the mouse rolls over the image... I know there is a .hover() jQuery function but am unsure how to use it to get the desired effect. Ideally when a user hovers over an image it would "grey out" (e.g. layer of 50% opacity black) with some HTML like a title etc etc. Can someone point me in the right direction or provide sample code Thanks

    Read the article

  • Importing images using subfloats in LaTeX

    - by melisma
    I am using subfloats to import 2 .png files in a figure to basically generate subfigures. There's no space between the figures when I compile it. How do I put some white space in between them? And is it possible to convert them to black and white using LaTeX?

    Read the article

  • "Proxying" HTTP requests

    - by Richard
    Hi all, I have some software which runs as a black box, I have no access to it. This software makes HTTP requests. What I want to do is intercept these requests, forward them on, catch the response, do something with it, before passing the response back to the software. Can this be done? What's the best method? Thanks

    Read the article

  • Why does jquery behave like this

    - by andrei
    $('.box').click(function(){ $(this).find('p').toggle( function () { $(this).css({"color" : "red"}); }, function () { $(this).css({"color" : "black"}); } ); }); if i execute this script the 'p' color will change if i click on the 'p' not on the .box class why ? And how to i make it so that 'p' color changes when i click on the .box div

    Read the article

  • Why is my view not resizing after rotating?

    - by E-Madd
    I'm only supporting the portrait orientation, but both the right-side-up and upside-down versions. Why do my subviews not resize appropriately? There's a status bar sized black space at the top of the view. If I change tabs and come back, it's corrected.

    Read the article

  • paragraph with vertical line on its left

    - by Flavius
    Hi What is the easiest way to have a paragraph with one or with two vertical black lines on its left? I have something like this so far: \newcommand{\attention}[1]{\begin{huge}!\end{huge} #1} But instead of a huge exclamation mark, I want a vertical line, whether the paragraph is one- or multi-line.

    Read the article

  • How does one programmatically download files from the web?

    - by ytrp
    How are files downloaded from servers in programming languages like C? I understand higher level languages have magic functions like "download_file_from_url()" but they don't help me understand what is actually going on. I'm a little familiar with sockets but network programming in general is still a black box to me. Thanks for any help.

    Read the article

  • confusing java data structures

    - by London
    Maybe the title is not appropriate but I couldn't think of any other at this moment. My question is what is the difference between LinkedList and ArrayList or HashMap and THashMap . Is there a tree structure already for Java(ex:AVL,Black-white) or balanced or not balanced(linked list). If this kind of question is not appropriate for SO please let me know I will delete it. thank you

    Read the article

  • Gradually enlarging text

    - by WCoastGuynCA
    I want to create a Flash or animated video that starts with a red dot on a black background. Gradually the dot increases in size and is actually text which says something such as "Buy American". How can this be done?

    Read the article

  • Plotting data with meshgrid

    - by Ruby
    When you use meshgrid to plot data (using meshgrid itself not one of the other plotting functions), how do you change the color to grayscale or black and white? Also, how do you get rid of the "meshy" look of the image?

    Read the article

  • KineticJS issue with repeatable mouse event

    - by nuclearpeace
    I have noob issue here (i obviously missing something). I simplified it from my bigger application: When i click blue rectangle, i add another layer to the stage that includes red rectangle (clickable), when i clik this red rectangle it removes second layer with red rect. Problem: When i click blue rect second time, nothing happens :( i.e. app works only once, and i need to add/remove second layer(with red rect) repeatedly. What's wrong? :) You can see it here, Fiddle http://jsfiddle.net/mAX8r/ Code: <!DOCTYPE HTML> <html> <head> <style> body { margin: 0px; padding: 0px; } canvas { border: 1px solid #9C9898; } </style> <script src="http://www.html5canvastutorials.com/libraries/kinetic-v4.0.3.js"> </script> <script> window.onload = function() { var stage = new Kinetic.Stage({ container: 'container', width: 578, height: 200 }); var layerBlue = new Kinetic.Layer(); var layerRed = new Kinetic.Layer(); var rectBlue = new Kinetic.Rect({ x: 100, y: 75, width: 100, height: 50, fill: 'blue', stroke: 'black', strokeWidth: 4 }); var rectRed = new Kinetic.Rect({ x: 300, y: 75, width: 100, height: 50, fill: 'red', stroke: 'black', strokeWidth: 4 }); // mouse events rectBlue.on('click', function() { stage.add(layerRed); stage.draw(); }); rectRed.on('click', function() { layerRed.remove(); stage.draw(); }); // add the shape to the layer layerBlue.add(rectBlue); layerRed.add(rectRed); // add the layer to the stage stage.add(layerBlue); }; </script> </head> <body> <div id="container"></div> </body> </html>

    Read the article

  • mysql: Can I use two "where"s? Like, "SELECT * FROM table WHERE something and something"?

    - by KeriLynn
    I have a table with my products and I'm trying to write a page that would pull bracelets with certain colors from the database. So here's what I have right now (in php): $query = "SELECT * FROM products WHERE (products.colors LIKE '%black%')"; But I only want to select rows where the value for the column "category" equals "bracelet". I've tried a few different things, but I keep getting warnings and errors. I appreciate any help you can give, thank you!

    Read the article

< Previous Page | 84 85 86 87 88 89 90 91 92 93 94 95  | Next Page >