position

Position javascript window.open centered on secondary screen?

馋奶兔 提交于 2019-12-12 06:06:42
问题 I have this code from an example: <script type="text/javascript"> function open_and_move2(){ win3=window.open("page.htm","","width=600,height=500") win3.moveTo(screen.width/2-300,screen.height/2-250) } </script> It works just fine with the exception that, if the browser window is located at a secondary screen, the javscript window pops up on the main screen. Seems like the calculated offsets would be correct for the secondary screen, but the offsets are executed on an absolute scope. I would

Adding constraints without auto-layout

点点圈 提交于 2019-12-12 05:46:26
问题 I am building an app with a modal view containing a UICollectionView and below it a view containing two buttons (validate/cancel). The number of rows in my UICollectionView can change depending on the data and don't know it beforehand so I want to add a constraint to always keep my buttons 30px below the collectionView. I am not using auto-layout for this as I have some animations which work better without it so I don't know how to programmatically add such constraints. Does anyone have any

Postilion eSocket.POS Structured xml data Tags

假如想象 提交于 2019-12-12 05:37:58
问题 Good day. i am hoping that someone could perhaps help me. We have been requested to make changes to our POS system when doing Electronic card payments. we have been requested to include a unique GUID for the transaction via structured xml to eSocket.POS. the current xml that we generate to create the request works correctly, but as soon as i include the structured xml element to the end i receive errors when doing the request. this is the line i am adding <Esp:StructuredData Name=\

Position of a modelmesh in XNA

Deadly 提交于 2019-12-12 05:37:14
问题 How do you find the vector 3 position of a mesh inside of a model in XNA(in global coordinates)? I've made a model of a simple lamp post in blender. Where the light should be, I've put a single vertice as its own object and named it "Light", in the position a typical light would be in a lamp post. In my XNA program, I want to put a floating point light at the position from the model. I can find the mesh by name. But need the Vector3 position of the "Light" mesh to do it. 回答1: It depends how

Position text at bottom, but letting it stay in document flow

佐手、 提交于 2019-12-12 05:13:25
问题 I have the following problem: There's an image floating left and a margin to the right. Next to it, there is a div containing a headline and a text (I don't know any height-values of both, because it will be inserted dynamically). The headline must align to the top and the text to the bottom. I thought it's enough to position the text absolute, but if the height of the image is smaller than the height of the headline + the text, the text flows into the headline.... I haven't found any

Positioning relative to table-cell

痞子三分冷 提交于 2019-12-12 04:57:49
问题 The effect of 'position:relative' on table-row-group, table-header-group, table-footer-group, table-row, table-column-group, table-column, table-cell, and table-caption elements is undefined. Source: http://www.w3.org/TR/CSS21/visuren.html#propdef-position Is there any idea to position relative to which I have set display property to table-cell using :before or :after selector? .someclass{display: table-cell; position: relative; z-index: auto;} /*this won't work*/ 回答1: IMHO: In browsers which

Fixed elements (HTML) break after android keyboard dissapears?

孤街醉人 提交于 2019-12-12 04:55:14
问题 I am trying to place a text input at the bottom of the viewport/screen. It works fine, it even "sticks" to the top of the keyboard after the onfocus event. When the keyboard is closed, however, there is lag between the changed position (top of keyboard) and the original position (bottom of viewport). My css for the element is : .fixed { position: absolute; z-index: 1000; height: 50px; display: block; bottom: 0px; width: 100%; } EDIT: This behavior doesn't depend on fixed/absolute positioning

IOS View still does not load in the correct position

懵懂的女人 提交于 2019-12-12 04:53:56
问题 I thought I had this cleared up but apparently not. I am using the code below to set a webview to appear between the top nag bar and tab bar at the bottom. This happens in my viewDidLoad() method. It was working fine on all simulators I had tested it on, however when I tested a friend's iPhone 4s running 7.1.1 the webview rendered spanning the entire height of the screen, covered by both the top nag bar and bottom tab bar. How to I get the desired behavior across all devices and OS above 7?

xsl finding relative position to ancestor node

安稳与你 提交于 2019-12-12 04:47:11
问题 Have some problems to get the position of childs division relative to the section node. Here is my XML file: <document> <section> <division>text of division</division> <division>text of division</division> <division>text of division</division> </section> <section> <division>text of division</division> <division>text of division</division> <division>text of division</division> </section> </document> And here is my XSL: <xsl:template match="/"> <xsl:for-each select="//section"> <div class=

Fixed positioning bug in Firefox 7.0.1, some overflow seems to cause 1px margin on fixed div

人走茶凉 提交于 2019-12-12 04:39:07
问题 This seems to be a bug specific to firefox (version 7.0.1), I have copied the offending code into jsFiddle. but jsFiddle DOES NOT REPRODUCE THE BUG . copy the code from jsFiddle into a blank html document and test it locally to see the issue. http://jsfiddle.net/kCMeu/1/ This is the normal state of the menu items before you over over any of them: This is the first sub_item when hovered over wiht the mouse: And the third sub_item: And now the last: Where did that white margin come from around