search for: getstyle

Displaying 20 results from an estimated 40 matches for "getstyle".

2005 Aug 31
4
Element.show - element.style.display=''''
...----------- ------------------- Details : [prototype.js] hide: function() { for (var i = 0; i < arguments.length; i++) { var element = $(arguments[i]); alert(''hide ''+element.id+'' : element.style.display [''+element.style.display+''] getStyle() [''+getStyle(element,''display'')+'']''); element.style.display = ''none''; alert(element.id+'' : element.style.display [''+element.style.display+''] getStyle() [''+getStyle(element,''displ...
2005 Dec 30
4
AJAX Drag and Drop Detecting Drop Coordinates
This one''s kicking me in the *(&#^. All I want to do is create a draggable item and then detect the coordinates where it is dropped. So my first approach was to just use the draggable_element with :revert => false, like so: <%= draggable_element "my_element", :revert => false %> That works great and lets me drag stuff all over the place. In the scriptaculous
2005 Sep 07
3
Autocomplete Error w/Version 1.5_pre4
...AutoCompletion. When text is entered in the text field for auto completion, the auto_complete div is not updated (but the server does receive the request and return a response). Upon removing focus from the text field, 2 instances of the following error can be seen in both FireFox and IE: Element.getStyle is not a function Source File: http://localhost:3000/javascripts/controls.js which refers to show: function() and hide: function() The line from show: function()---- if(Element.getStyle(this.update, ''display'')==''none'') this.options.onShow(this.element, this.upd...
2008 Apr 22
2
getStyle({margin}) on TD element is null in IE
The same applies for the single margin values e.g. -left, -right, - top, -bottom; --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to
2010 Feb 09
1
odfTable: table width and alignment
Dear R and odfWeave users, I am trying to figure out how to control table width and alignment on the page for a table generated by odfTable. Based on reading odfWeave documentation (including formattingOut.odt), here is how I manipulate the styles: st = getStyleDefs() # modify the table style tab = getStyles()$table st[[tab]]$align = "center" # seems to have no effect st[[tab]]$marginLeft = "2.0 in" # seems to have no effect setStyleDefs(st) My table always ends up fully justified (taking all page width). When I check Ta...
2008 Jun 19
7
getDimensions() fails for elements with ancestors with display: none
Prototype v1.6.0.2 If any of an element''s ancestors are hidden, Element.getDimensions() returns misleading values. In order to address this in my own project, I made the following modification: getDimensions: function(element) { element = $(element); var display = element.getStyle(''display''); + var hiddenAncestor = element.ancestors().any(function(e) { return e.getStyle(''display'') == ''none''; }); - if (display != ''none'' && display != null) // Safari bug + if (display != ''none...
2005 Oct 26
2
Troubleshooting inplace editor
...k me, click me!</p> <script language="JavaScript"> new Ajax.InPlaceEditor(''editme'', ''/demoajaxreturn.html''); </script> 3. The page loads okay, but no Ajax magic. 4. My javascript console displays the following errors: Error: Element.getStyle is not a function Source File: http://127.0.0.1:3000/javascripts/controls.js Line: 474 Line 474 from control.js is this: this.originalBackground = Element.getStyle(this.element, ''background-color''); if (!this.originalBackground) { this.originalBackground = "transparent"...
2005 Nov 21
0
New Core Effect
...{ initialize: function(element, property) { this.element = $(element); this.property = property; var options = Object.extend({ toRight: null, toLeft: null, toTop: null, toBottom: null }, arguments[2] || {}); this.originalRight = parseFloat(Element.getStyle(this.element, property + ''-right'') || ''0''); this.originalLeft = parseFloat(Element.getStyle(this.element, property + ''-left'') || ''0''); this.originalTop = parseFloat(Element.getStyle(this.element, property + ...
2006 Jun 23
4
Creating a scrolling effect with slider
...ples: http://knowmad.com/~ian/scroller/scroller_slide.html http://knowmad.com/~ian/scroller/scroller_blind.html I was originally wanting to use slide, but It spits out errors in firebug: effects.js (line 736) <view-source:http://knowmad.com/%7Eian/scroller/effects.js>$(element.firstChild).getStyle is not a function Thanks, Ian
2006 Nov 28
11
Extending Element with getTop, getWidth, getLeft problem
Hi, I need to extend the Element object with getTop, getWidth, getLeft . I wrote something like this in an js file and loaded it after the prototype.js . ---------------------------------------------------- Object.extend(Element, { getWidth: function(element) { element = $(element); return element.offsetWidth; }, getTop: function(element) { element = $(element); var curtop
2009 Jul 07
0
[PATCH server] Update app to work with rails 2.3.2
...('\n')) this.options.tokens.push('\n'); this.observer = null; - + this.element.setAttribute('autocomplete','off'); Element.hide(this.update); @@ -91,10 +91,10 @@ Autocompleter.Base = Class.create({ show: function() { if(Element.getStyle(this.update, 'display')=='none') this.options.onShow(this.element, this.update); - if(!this.iefix && + if(!this.iefix && (Prototype.Browser.IE) && (Element.getStyle(this.update, 'position')=='absolute')) { - new Inser...
2006 Feb 16
3
Retrieve a property defined in a css
Hi all, I have a property, defined in an external stylesheet: .my_class { background-color: #FF0000; } I want to retrieve the value of this background-color of the class my_class. How can I do that with prototype/scriptaculous ? Thanks in advance, Nicolas Terray
2006 Feb 08
6
Effect Help
I posted the following earlier: "I need a way to do a blind up that makes the element APPEAR and a blind down that makes the element DISAPPEAR. In essence, the opposite of the current blindup/blinddown. Thoughts?" I think somebody responded in Dutch. Anyone else have any ideas? -- Yehuda Katz Web Developer (ph) 718.877.1325 (fax) 718.686.4288
2005 Nov 07
2
question about Effect.Highlight and IE 5.5
...ant to change them or not. Here''s what I know: In Effect.Highlight.setup (line 532 in the rc4 version of effects.js), it does an element.style.backgroundColor to determine the ''restorecolor''. This doesn''t seem to work in IE 5.5, and if you switch it to Element.getStyle(this.element, ''background-color'') (as is done a few lines earlier when determining the ''endcolor''), it works correctly. Should this be changed? That, however, doesn''t fix the problem. The problem is that IE 5.5 seems to ignore setting the style.back...
2005 Aug 11
7
script.aculo.us V1.5_pre1 released
...utocompleter [Rob Sharp] * Added Ajax.InPlaceEditor to controls.js [Jon Tirsen] * Fixes a bug with Droppables not recognizing a drop if no hoverclass is given [thanks drewie] * Changed Effect.Opacity to better handle 100% opacity * Added ghosting option to Draggables and Sortables * Added Element.getStyle to find computed CSS styles of an element Mostly, I''m interested in Bugs and Browser compatibility. If you patch something, be sure to grab the SVN trunk. I''m away from tomorrow until monday or tuesday, so i hope to get plenty of reports in by then. :) Thomas
2006 Dec 19
2
Effect.Pulsate on last scriptaculous
...#39;') { if (value == 1) { value = (/Gecko/.test(navigator.userAgent) && !/Konqueror|Safari|KHTML/.test(navigator.userAgent)) ? 0.999999: 1.0; if(/MSIE/.test(navigator.userAgent) && !window.opera) element.style.filter = element.getStyle (''filter'').replace(/alpha\([^\)]*\)/gi,''''); } else { if(value < 0.00001) value = 0; if(/MSIE/.test(navigator.userAgent) && !window.opera) element.style.filter = element.getStyle(''filter'').replac...
2006 Feb 08
2
Prototype: Position.clone()
...e source = $(source); var p = Position.page(source); // find coordinate system to use target = $(target); var delta = [0, 0]; var parent = null; // delta [0,0] will do fine with position: fixed elements, // position:absolute needs offsetParent deltas if (Element.getStyle(target,''position'') == ''absolute'') { parent = Position.offsetParent(target); delta = Position.page(parent); } // correct by body offsets (fixes Safari) if (parent == document.body) { delta[0] -= document.body.offsetLeft; delta[...
2009 Jul 20
9
Upgrade server to run on Rails 2.3.2/F11
Note that one of the 8 patches (#6) will be sent separately in reply to this email, as some of the replaced lines are too long, so git won't let me send the email. However, there is nothing wrong with that patch, and it should be applied in the sequence listed below. Note also that I assume this will be tested on a clean f11 install, rather than an upgrade of an existing ovirt server
2006 Apr 20
1
The Autocompleter, with scrollable result-div
...this.iefix, {setTop:(!this.update.style.height)}); this.iefix.style.zIndex = 1; this.update.style.zIndex = 2; Element.show(this.iefix); @@ -176,6 +176,13 @@ }, onBlur: function(event) { + // Dont hide the div on "blur" if the user clicks scrollbar + if(Element.getStyle(this.update, ''height'') != ''''){ + if( Position.within( this.update , Event.pointerX(event) , Event.pointerY(event) ) ){ + Event.observe(this.update, "blur", this.onBlur.bindAsEventListener(this),true); // make sure blur is still around...
2006 Apr 05
7
Conditional toggle button
I have a link_to_remote that updates the content of a hidden div and makes it appear.. But I want it to hide the div and not execute the link_to_remote function on the second click. What''s the best way to do this? I''m thinking I can do it in RJS maybe, but I''m not sure if there''s a nice Rails-y way to tell if a div is hidden or not.. I''d also