Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

158 Neutral

About lincsimp

  • Rank
  1. Hi As part of a function which is executed very many times I have a switch statement that will act based on the closed set of inputs S. S={0,1,2,3,4}; I know that the default can never be reached. Is there anything I can do to speed execution without writing jump tables myself? Is there any intrinsic or anything to tell the compiler that it can't happen? cheers
  2. hi how can i give vs2005 a set of include paths to search through for every? cheers
  3. Does anyone have any idea how to change the width of a frame dynamically when a page is loading without it going to its original value and then suddenly changing? cheers
  4. Yeah, I used: document.body.cols = "whatever" and I got rid of the boy tag at the bottom which, for some reason, sorted the problem.... cheers
  5. hey I've got a problem setting the width of a frame ("leftFrame") using javascript. this is my page: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Untitled Document</title> <SCRIPT LANGUAGE="javascript"> window.onload = function(){ width = document.frames[0].outerWidth; //document.getElementByID("fs").setAttribute("cols","1000,*"); alert('Width = ' + width); } //</SCRIPT> </head> <frameset cols="300,*" frameborder="no" border="0" framespacing="0" id="fs"> <frame src="left.php" name="leftFrame" scrolling="No" noresize="noresize" id="leftFrame" /> <frame src="main.php" name="mainFrame" id="mainFrame" /> </frameset> <noframes><body> </body> </noframes></html> You can see above what I've tried, but I can't seem to get it to work. Can anyone help? cheers
  6. Thanks.For the images I'm using the background repositioning to "preload" them ( http://www.ilovejackdaniels.com/css/preloading-images-with-css/ ). I dont know whether its the images because the problem does no occur if you move the mouse up and down after the ends of the words, even though the background is still being changed. Cheers
  7. Hey there, http://www.matix.co.uk/readyhelp/demo/ When you move the mouse in IE up and down between "Tutorials" and "FAQ" a wait cursor momentarily appears. This does not occur in FF. How can I sort it out? This is the div code: Code: <div class="folder menuitem" onmouseover="this.className='folderhover menuitem'" onmouseout="this.className='folder menuitem'" onclick="this.setAttribute('clicked','true');montre()">Tutorials Cheers
  8. lincsimp

    xerces problem

    Thanks, I don't see why it would return null, here's the code: XMLCh tempStr[100]; XMLString::transcode("Range", tempStr, 99); DOMImplementation* impl = DOMImplementationRegistry::getDOMImplementation(tempStr); XMLString::transcode("root", tempStr, 99); DOMDocument* doc = impl->createDocument(0, tempStr, 0); DOMElement* root = doc->getDocumentElement(); XMLString::transcode("FirstElement", tempStr, 99); DOMElement* e1 = doc->createElement(tempStr); root->appendChild(e1); XMLString::transcode("SecondElement", tempStr, 99); DOMElement* e2 = doc->createElement(tempStr); root->appendChild(e2); XMLString::transcode("aTextNode", tempStr, 99); DOMText* textNode = doc->createTextNode(tempStr); e1->appendChild(textNode); // optionally, call release() to release the resource associated with the range after done DOMRange* range = doc->createRange(); range->release(); // removedElement is an orphaned node, optionally call release() to release associated resource DOMNode* removedElement = root->removeChild(e2); removedElement->release(); // no need to release this returned object which is owned by implementation XMLString::transcode("*", tempStr, 99); DOMNodeList* nodeList = doc->getElementsByTagName(tempStr); //DOMNode* test = (DOMNode)root; const XMLCh* value=root->getNodeValue(); cout<<w2n(value)<<endl; can anyone give some guidance???? cheers
  9. lincsimp

    xerces problem

    Thanks! I have this: const XMLCh* value=root->getNodeValue(); cout<<w2n(value)<<endl; I got an error: Unhandled exception at 0x00418755 in LanguageConverter.exe: 0xC0000005: Access violation reading location 0x00000000. at this line: for ( ; *ptr; ++ptr ) whats wrong?
  10. hi I've just started using xerces with c++. How can I output the xmlch? const XMLCh* value=root->getNodeValue(); cout<<"["<<value<<"]"<<endl; This just ouptuts [00000000] How can i output the node value? cheeers
  11. hi In my xml file I have this line: <?xml-stylesheet type="text/xsl" href="../styles/test3.xsl" ?> it alll works fine in IE, but in FF it can't find the stylesheet. How can I change this? cheers
  12. I found: parent.frames['mainFrame'].FunctionName(args);
  13. Hi How can I do this? I know parent.frames["name] lets me access the other frame, but how can I call a function in it?
  14. lincsimp

    Quick type question..

    How didn't I spot that!! It should at least have given me a decent error...
  15. Hey Apart from game programming I need to spend some time on revision... I'v ethe following function in my prog: unsigned Lookup(string input) { string lookuptable[] = {"adj","adj plural","adv","conj","noun 1","noun 2","noun 3", "noun 4","noun 5","noun irreg","noun/adj","partic","prep","pron","pron/ adj","verb", "verb 1","verb 1 dep","verb 2","verb 2 impers","verb 3","verb 3 dep","verb 4", "verb defect.","verb imperat","verb imperative","verb irreg","verb phrase"}; for(unsigned i=0;i<28;i++) { if(lookuptable=input) return i; } cout<<"type not found "<<input<<endl; return 0; } When compiled in mingw why do I get the error: helperfuncs.h could not convert `(&temp)->std::basic_string<_CharT, _Traits, _Alloc>::operator= [with _CharT = char, _Traits = std::char_traits<char>, _Alloc = std::allocator<char>](((const std::basic_string<char, std::char_traits<char>, std::allocator<char> >&)((const std::basic_string<char, std::char_traits<char>, std::allocator<char> >*)(&ti))))' to `bool' Can anyone shed some light?? cheers
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!