Search Results

Search found 2033 results on 82 pages for 'absolute'.

Page 7/82 | < Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • HTML5: Rendering absolute images using canvas

    - by Mark
    I am experimenting with canvas as part of my HTML5 introduction. This constitutes as assignment work, but I am not asking for any help on the actual coursework at all. I am trying to write a rendering engine, but having no luck because once the image is drawn on canvas it looks very distorted, and not at the right dimensions of the image itself. I have made a animation engine that loads images into an array, and then iterates through them at a certain speed. This is not the problem, and I assume is not causing the issue as this was happening when I drawn an image to the canvas. I think this is natural behaviour for images to be scaled/skewed when the window is resized, so I conquered that by simply redrawing the whole thing once the window is resized. The images I am using are isometric, and drawn at a pixel level. Would this cause the distortion? It seems setting the dimensions on the drawImage() function are not working are all. I am using JavaScript for the manipulation and rendering of the canvas. I would normally try and work it out myself, but I do not have any time to ponder why because I have no idea why it is even scaling/skewing the image once it is drawn on the canvas. I cannot share the code for obvious reasons. I should also mention, the canvas's dimension is the total width of the viewport, as I am developing a game. My question is: Has anyone encountered this and how would I correct it? Thanks for your help.

    Read the article

  • absolute audio synchronization

    - by user1780526
    I would like to synchronize my computer with an external camcorder recording so that I can know exactly (to the millisecond) when certain recored events happen with respect to other sensors logged by the computer. One idea is to playback short sound pulses or chirps every second from the computer that get picked up by the microphone on the camcorder. But the accuracy of a simple cron job playing a sound clip is not precise enough. I was thinking of using something like gstreamer, but how does one get it to playback a clip at precisely a certain time according to the system clock?

    Read the article

  • Clear Absolute Cache on Application close Ipad app

    - by geeth
    I am saving Images in NSCachesDirectory in a App. At the end of app execution i would like to clear all temporary cache. Is there a way to force clear all cache on application exit. I do realise the local folder keeps cache for 3 days..but my requirement is to force clear the Cache. Thx

    Read the article

  • Getting a divs z-index to overlap a div with absolute positioning

    - by Paul Herron
    Does anyone know how I could get the logo at the top of my page to appear on top of the curtains. http://nuigums.tumblr.com/ The logo is within a section tag along with the rest of the content with a z-index of 2, which is required to get the footer reveal effect I want. The curtain has a z-index of 3. I tried setting the z-index of the logo div to 4 but I presume the fact that the sections styling overrides that? I would like the logo to scroll with the content of the page also. Thanks. :)

    Read the article

  • jQuery dialog width resizing problem

    - by ktMen
    I try to load some HTML code into a jQueryUI dialog by AJAX. The code itself is a list, where rightmost elements should be absolutely positioned so that the list looks like a table with two columns, but only in some rows. The problem is that jQueryUI plugin does not seem to be correctly resizing the dialog's width, which I think is due to the absolute positioning of some li's. I have read some answers to other similar questions, but none helped me out with this. This is the code I load: <style type="text/css"> ul {list-style-type:none;margin:0px;padding:0px;} ul ul {margin:0px;padding:0px;} ul>li.fila {margin-bottom:5px;padding-bottom:5px;} ul li.fila ul li { display:inline; padding-left:20px; position:relative; margin-bottom:10px; } ul li.fila ul li.O { background:url(bullet.gif) 5px 8px no-repeat; list-style-position:inside; } </style> <ul id="raiz" > <li class="fila"> <ul > <li style="position:absolute;left:0px;" class="O"> <label for="col1">Col1:</label> <input type="text" name="col1" id="col1" value="vCol1" class="text ui-widget-content ui-corner-all" /> </li> <li style="left:250px;" class="O" > <label for="col2">Col2:</label> <input type="text" name="col2" id="col2" value="vCol2" class="text ui-widget-content ui-corner-all" /> </li> </ul> </li> <li class="fila"> <ul > <li> <label for="col3">Col3:</label> <input type="text" name="col3" id="col3" value="vCol3" class="text ui-widget-content ui-corner-all" /> </li> </ul> </li> </ul> And the Dialog constructor: $("#dialog").dialog({ bgiframe: true, autoOpen: false, height: 'auto', width: 'auto', modal: true, buttons:{ 'Cancel': function() { $(this).dialog('close'); } }, open: function(event,ui){ $("#dialog").load("dialogCode.html"); } }); Thanks in advance for any suggestions.

    Read the article

  • how do I make my submenu position dynamic based on the distance to the edge of the window?

    - by Mario Antoci
    I'm trying to write a jQuery script that will find the distance to the right edge of the browser window from my css class element and then position the child submenu dropdowns to the right or left depending on the available space to the right. Also it needs to revert to the default settings on hoverout. Here is what I have so far but it's not calculating properly. $(document).ready(function(){ $('#dnnMenu .subLevel').hover(function(){ if ($(window).width() - $('#dnnMenu .subLevel').offset().left - '540' >= '270') { $('#dnnMenu .subLevelRight').css('left', '270px');} else {$('#dnnMenu .subLevelRight').css('left', '-270px');} }); $(document).ready(function () { function HoverOver() { $(this).addClass('hover'); } function HoverOut() { $(this).removeClass('hover'); } var config = { sensitivity: 2, interval: 100, over: HoverOver, timeout: 100, out: HoverOut }; $("#dnnMenu .topLevel > li.haschild").hoverIntent(config); $(".subLevel li.haschild").hover(HoverOver, HoverOut); }); Basically I tried to take the width of the current window, minus the distance to the left edge of the browser of the first level submenu, minus the width of both elements together which would equal 540px, to calculate the distance to the right edge of the window when the first level submenu is hovered over. if the distance to the right of my first level submenu element is less than 540px then the second level sub menu css property is changed to position to the left instead of right. I also know that it needs to revert back to default after hover out so it can recalculate the distance from other positions within the menu structure and still have those second level submenus with enough room to still display on the right of the first level. here is css for the elements in question. #dnnMenu .subLevel{ display: none; position: absolute; margin: 0; z-index: 1210; background: #639ec8; text-transform: none;} #dnnMenu .subLevelRight{ position: absolute; display: none; left: 270px; top: 0px;} The site's not live yet and I tried to create a jsfiddle but it doesn't look right. Any help would be greatly appreciated! Best Regards, Mario

    Read the article

  • IE6 positioning issue

    - by Ralph The Mouf
    Here is the CSS...how can I make it layout as it should in IE6? .AuthorName_Pic { width:186px; position:absolute; right:0px; bottom:-120px; padding:20px 10px 20px 15px; margin:20px 0px 0px 0px; background:url(images/ThumbDark.jpg) no-repeat; z-index:100; }

    Read the article

  • css style "bottom:0" in dynamic <div>

    - by baruch
    I have an absolutely positioned element at the bottom of a container element. The problem is that the content of the container changes dynamically (javascript). In FF it still works fine, but IE7 (didn't test any others) seems to calculate the position of the element relative to the top of the container on page loading, and then doesn't update it. examples: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="he"> <head> </head> <body> <div style="position:relative;" onmouseover="document.getElementById('test').style.display='block'" onmouseout="document.getElementById('test').style.display='none'"> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> <div id="test" style="display:none;"> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> </div> <div style="position:absolute;bottom:0;background-color:blue;"> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> </div> </div> </body> </html> and the opposite: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="he"> <head> </head> <body> <div style="position:relative;" onmouseover="document.getElementById('test').style.display='none'" onmouseout="document.getElementById('test').style.display='block'"> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> <div id="test" style="display:block;"> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> </div> <div style="position:absolute;bottom:0;background-color:blue;"> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> rufaurhf refhwrew regfnwreug wurwsuref erfbw rebvwsrefg</br> </div> </div> </body> </html> Any ideas/workarounds?

    Read the article

  • Css positioning problem

    - by 2x2p1p
    Hi guys. I did a "shadow" effect but the "div" elements must have a relationship (father and son) <style> div { left: 3px; position: absolute; font-size: 60px; top: 3px; } div + div { position: relative; } </style> <div> shadow <div> shadow </div> </div> Can I make the same thing with separate elements like this bellow ? <div>shadow</div> <div>shadow</div> Thanks :)

    Read the article

  • Regex to replace relative link with root relative link

    - by Kendall Hopkins
    I have a string of text that contains html with all different types of links (relative, absolute, root-relative). I need a regex that can be executed by PHP's preg_replace to replace all relative links with root-relative links, without touching any of the other links. I have the root path already. Replaced links: <tag ... href="path/to_file.ext" ... > ---> <tag ... href="/basepath/path/to_file.ext" ... > Untouched links: <tag ... href="/any/path" ... > <tag ... href="protocol://domain.com/any/path" ... >

    Read the article

  • Overlapping two divs and 'clearing' their parent div

    - by brady8
    My CSS-fu is letting me down here: What I'd like to do is position two child divs to be overlapping: Using position: absolute; top: 0px; left: 0px; is the only way I know how, with the parent set to position: relative. The problem with this is that the child divs are taken out of the layout as per the CSS spec, shrinking the parent div to height: 0px, so that I can't clear that div and put any content below. My amazing ASCII art below details what I'm going for... any ideas? As an aside, I need these divs to be overlapping exactly for jQuery fades, and maybe trying out some of the new Webkit transforms, a la Apple's cardflip demo: http://developer.apple.com/safari/library/samplecode/CardFlip/Introduction/Intro.html If there's another way to get them overlapped exactly in CSS, I'm all ears. Thanks! |-------------------------------------------------| | Parent div | | |-------------------------------------------| | | | | | | | DIVS 1 & 2 (overlapped) | | | | | | | |-------------------------------------------| | |-------------------------------------------------| ...more content below, after clearing the parent...

    Read the article

  • Can FileOutputStream() take a relative path as an argument

    - by Ankur
    I am creating a FileOutputStream object. It takes a file or String as an argument in its constructor. My question is, can I give it a relative URL as an argument for the location of a file, it doesn't seem to work, but I am trying to work out if this is possible at all (if not I will stop trying). If it is not possible, how can I (from a servlet) get the absolute path (on the filesystem, not the logical URL) to the current location in such a way that I can pass that to the constructor. Part of my problem is that my dev box is Windows but I will publish this to a Unix box, so the paths cannot be the same i.e. on Windows C:/.... and on unix /usr/...

    Read the article

  • Positioning a tooltip relative to another div in JQuery

    - by James P
    Here's my tooltips markup and CSS: <div class="tooltip">Click here to like it</div> .tooltip { position: absolute; display: none; background: url('images/tooltip.gif') no-repeat; width: 100%; height: 40px; font-size: 0.8em; line-height: 40px; padding: 0px 0px 0px 8px; } Now, I have a div on my page called #button_container. I would like to place this .tooltip div 150px to the right of that div via JQuery. I understand I need to set this tooltips top and left attributes, but not sure how. Idealy the tooltips top attribute should be the same as #button_container (although #button_container isn't positioned absolutely) and 150 less than #button_container's left attribute. I don't really know where to get started on this so any help would be very much appreciated. Thanks.

    Read the article

  • jQuery Dialog open hides background content in IE7

    - by JoshReedSchramm
    Hey all, I'm working on an application where the page layout is essentially a bunch of absolutely positioned containers. There is a header, sidebar and content area. The content area has its own header and footer which are fixed on the screen. The main part of the content area scrolls but nothing else does. So, we are using jQuery dialog for popup boxes and in IE7 with this new layout when i open a dialog the rest of my content in the background vanishes. I'm left with the page header and the footer of the content area and that's it. In Firefox and believe it or not IE6 it works fine. We are using ie7.js in ie6 though to make things not suck. Anyone have any clue why opening a dialog in jquery would screw up absolute positioning and make stuff vanish?

    Read the article

  • Getting URL of executing JavaScript file (IE6-7 problem mostly)...

    - by TooTallNate
    Hey all, I've been trying to throw together a generic function that retrieves the absolute URL of an executing JavaScript file on a web page: http://gist.github.com/433486 It works great in almost all the browsers I've tested (Firefox, Chrome, Safari, Opera v10 at least, and IE 8). It seems to fail, however, in IE 6 and 7. The callback function gets executed, but the retrieved name is simple the URL to the main HTML page, not the JavaScript file. So all I'm really asking is if there's some other way of getting the URL of the current JavaScript file (which could be IE 6 and 7 specific)? Thanks in advance!

    Read the article

  • Les décideurs IT s'occupent-ils assez de la sécurité des appareils nomades ? Absolute Software sort un classement des vols les plus insolites

    Absolute Software sort un classement des vols d'ordinateurs les plus insolites Les décideurs IT s'occupent-ils assez de la sécurité des terminaux nomades ? Absolute Software, spécialiste canadien des solutions anti-vols des ordinateurs portables, vient de publier une bien curieuse rétrospective de l'année 2010. L'entreprise dresse en effet le top 5 des histoires de vol les plus insolites de l'année, des histoires qui finissent bien, et ce, bien entendu, grâce à ses solutions anti-vols. L'histoire sacrée la plus insolite est celle d'un acheteur malchanceux qui acquière un ordinateur portable d'occasion ? volé. L'acheteur se rend chez un ami policier afin d'utiliser s...

    Read the article

  • DIVS over flash movies in Internet Explorer

    - by drew
    The age old question... why the hell doesn't a div positioned over a flash object stay on top with z-index. I have found the answer in the past, but it's been so long, I can't seem to get it. My flash movie is in a div floating left: <div id="flash"> <object width="614" height="289"> <param name="movie" value="images/75.swf"> <param name="wmode" value="transparent"> <embed src="images/75.swf" width="614" height="289" wmode"transparent"> </embed> </object> </div> My css for the div that needs to be on top is: .menu ul li:hover ul li a:hover { background:#5a3f2d; color:#FFF; z-index: 9999; I cannot get it to show above the flash movie in ie6 or ie8. I know this is old school but I'm frustrated! Does my nav div need to have an absolute position? Is that why it doesn't work? Example is here. Hover over the first link on the right: "CUSTOMER SERVICE" Thanks all :)

    Read the article

  • Absolutely positioned div on right causing scrollbar when the left doesn't

    - by Michael Snyder
    I'm trying to "flank" a centered div with some design elements that are absolutely positioned outside the main div's width. I'm getting a scroll bar due to the element on the right, but not the element on the left (IE6/7/8, Chrome, Firefox). How can I get rid of that horizontal scrollbar? <html> <head> <style type="text/css"> html, body { height: 100%; width: 100%; margin: 0; } body { text-align: center; } .wrapper { margin: 0 auto; position: relative; width: 960px; z-index: 0; } .main { background: #900; height: 700px; } .right, .left { position: absolute; height: 100px; width: 100px; } .right { background: #090; top: 0px; left: 960px; z-index: 1; } .left { background: #009; top: 0px; left: -100px; z-index: 1; } </style> </head> <body> <div class="wrapper"> <div class="main"></div> <div class="left"></div> <div class="right"></div> </div> </body> </html>

    Read the article

  • How to combine a relative top with an absolute bottom in CSS?

    - by ceving
    I need to define a div which must stay with the top at the normal position, which differs from the top of the surrounding element: position:relative top:0 and which grows in the height up to the size of the surrounding element: position:absolute bottom:0 I have no idea how to combine the both. Whenever I use a relative box I loose the absolute bottom and whenever I use an absolute box I loose the relative top. Can anybody help me how to do this in CSS? Here is an example: <html> <head> </head> <style type="text/css"> @media screen { body { position: absolute; top: 0; left: 0; right: 0; bottom: 0; margin: 0; padding: 0; } #head { background-color: gray; } #rel { background-color: green; position: relative; top: 0; bottom: 0; float: left; } #abs { background-color: red; position: absolute; top: 0; bottom: 0; float: left; } } </style> <body> <div id="head"> <h1>Head</h1> </div> <div id="abs"> <h2>absolute</h2> </div> <div id="rel"> <h2>relative</h2> </div> </body> </html> "relative" does not grow at all and "absolute" grows too much.

    Read the article

  • CSS positioning breaks in Safari

    - by user298638
    Hi all, i have a website in which i am trying to position (using CSS) a certain on the page. the is absolutely positioned and is located inside a relatively positioned paernt . on firefox and even IE it looks ok but on Safari, things get messy and it shows 5 pixels lower than it should. i have tried to figure out for days now what is wrong there but cannot seem to see it. you can find an example link to the problematic page here: http://yaronattar.com/index.php?option=com_content&view=article&id=117:the-new-lovers-2010&catid=51:the-new-lovers-2010&Itemid=242 the problematic is the one conaining the "previous/next" navigation at the bottom right corner of the page. anyone sees what is causing the trouble here? thanks

    Read the article

  • Relative Uri works for BitmapImage, but not for MediaPlayer?

    - by Thomas Stock
    This will be simple for you guys: var uri = new Uri("pack://application:,,,/LiftExperiment;component/pics/outside/elevator.jpg"); imageBitmap = new BitmapImage(); imageBitmap.BeginInit(); imageBitmap.UriSource = uri; imageBitmap.EndInit(); image.Source = imageBitmap; = Works perfectly on a .jpg with Build Action: Content Copy to Output Directory: Copy always MediaPlayer mp = new MediaPlayer(); var uri = new Uri("pack://application:,,,/LiftExperiment;component/sounds/DialingTone.wav"); mp.Open(uri); mp.Play(); = Does not work on a .wav with the same build action and copy to output. I see the file in my /debug/ folder.. MediaPlayer mp = new MediaPlayer(); var uri = new Uri(@"E:\projects\LiftExp\_solution\LiftExperiment\bin\Debug\sounds\DialingTone.wav"); mp.Open(uri); mp.Play(); = Works perfectly.. So, how do I get the sound to work with a relative path? Why is it not working this way? Let me know if you want more code or screenshots. Thanks.

    Read the article

  • Flash under dhtml menu

    - by David
    I'm struggling with this probelm for few hours and it's drives me crazy. I want my drop down menu put over flash area and it works but only in FF. Unfotunelly IE and Opera shows my menu under flash. The DHTML menu system is the simplest as possible and it was wrote from scratch by me. I've been trying everything, and still it doesn't work like it should. I tried to put the flash element by jquery.flashEmbed script and by standard code with param transparent, but it never works. Plese help me, I'm loosing my head. Here is the xhtml: http://www.project.yamandi.com/toton/ Regards, David

    Read the article

  • Relative path from an ASP.NET user control NavigateUrl

    - by Daniel Ballinger
    I have a user control that contains a GridView. The GridView has both a HyperLinkField column and a template column that contains a HyperLink control. The ASP.NET project is structured as follows, with the Default.aspx page in each case using the user control. Application Root Controls UserControl with GridView SystemAdminFolder Default.aspx Edit.aspx OrganisationAdminFolder Default.aspx Edit.aspx StandardUserFolder Default.aspx Edit.aspx Note: The folders are being used to ensure the user has the correct role. I need to be able to set the DataNavigateUrlFormatString for the HyperLinkField and the NavigateUrl for the HyperLink to resolve to the Edit.aspx page in the corresponding folder. If I set the navigate URL to "Edit.aspx" the URL in the browser appears as 'http://Application Root/Controls/Edit.aspx' regardless of the originating directory. I can't use the Web application root operator (~/) as the path needs to be relative to the current page, not the application root. How can I use the same user control in multiple folders and resolve the URL to another page in the same folder? Note: The question is strongly based off a similar question by azhar2000s on the asp.net forums that matches my problem.

    Read the article

< Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >