Search Results

Search found 3788 results on 152 pages for 'pure equal'.

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

  • Preserving equal sized split view

    - by Gökhan Sever
    Hello, I start GVIM in not-maximized window mode and split its window horizontally making sure the windows are equally sized. How can I preserve this equal-sized split view when I maximize the main GVIM window? Whenever I maximize GVIM forgets that the windows have been equally split. Thanks.

    Read the article

  • textbox required equal false

    - by Donato bruno comunali F. dutra
    how do I make the textbox that required equal to false in this code $(document).ready(function () { $("#<%= chkSpecialIntegration.ClientID %>").click(function () { if (this.checked) { $("#<%= ddlTypeSpecialIntegration.ClientID %>").show(); document.getElementById('<%=txtTotalScoreDebit.ClientID %>').Required = false; } else{ $("#<%= ddlTypeSpecialIntegration.ClientID %>").hide(); document.getElementById('<%=txtTotalScoreDebit.ClientID %>').Required = true; } }); });

    Read the article

  • Equal Height Columns with Cross-Browser CSS

    - by Frank Michael Kraft
    I want to have divs of the same height. http://matthewjamestaylor.com/blog/equal-height-columns-cross-browser-css-no-hacks does not work for be because my divs have a border, and the method described assumes, that they have not. A jQuery solution I could not make work, because my divs resize late because of ajax and menu clicks and I can not find an event for this.

    Read the article

  • Setting height of div equal to containing div

    - by Syom
    i have the following simple script <div id="content"> <div id="left"> <div id="menu"> <ul> <li>menu</li> </ul> </div> <div id="left_ad"> </div> </div> <div id="middle"> some text here... </div> <div id="right"> <div id="right_ad"> <div id="ad2"> </div> </div> </div> </div> css: #content { margin: 0; padding: 0; overflow: hidden; position: relative; } #left { float: left; width:25%; margin-left:0; margin-right:0; margin-top:0; margin-bottom:-5000px; padding-left:0; padding-right:0; padding-top:0; padding-bottom:5000px; } #middle { background-image:url("http://localhost/kino/img/theme.png"); background-repeat:no-repeat; float: left; width:50%; margin-left:0; margin-right:0; margin-top:0; margin-bottom:-5000px; padding-left:0; padding-right:0; padding-top:0; padding-bottom:5000px; } #right { float: left; width:25%; margin-left:0; margin-right:-1px; margin-top:0; margin-bottom:-5000px; padding-left:0; padding-right:0; padding-top:0; padding-bottom:5000px; } #left_ad { background-image:url("http://localhost/kino/img/lens1.png"); background-repeat:no-repeat; min-height:498px; margin-left: auto; margin-right: auto; margin-top:31px; padding:0; width: 188px; position: relative; height: 100%; } as you see, left, middle and right have the same size of heigth, which is equal to max of them. and now, what is the question, i want left_ad to have the same heigth too. how can i set the heigth of left_id is equal to left? thanks

    Read the article

  • setting heigth of div equal to containing div

    - by Syom
    i have the following script <div id="content"> <div id="left"> <div id="menu"> <ul> <li>menu</li> </ul> </div> <div id="left_ad"> </div> </div> <div id="middle"> some text here... </div> <div id="right"> <div id="right_ad"> <div id="ad2"> </div> </div> </div> </div> css: #content { margin: 0; padding: 0; overflow: hidden; position: relative; } #left { float: left; width:25%; margin-left:0; margin-right:0; margin-top:0; margin-bottom:-5000px; padding-left:0; padding-right:0; padding-top:0; padding-bottom:5000px; } #middle { background-image:url("http://localhost/kino/img/theme.png"); background-repeat:no-repeat; float: left; width:50%; margin-left:0; margin-right:0; margin-top:0; margin-bottom:-5000px; padding-left:0; padding-right:0; padding-top:0; padding-bottom:5000px; } #right { float: left; width:25%; margin-left:0; margin-right:-1px; margin-top:0; margin-bottom:-5000px; padding-left:0; padding-right:0; padding-top:0; padding-bottom:5000px; } #left_ad { background-image:url("http://localhost/kino/img/lens1.png"); background-repeat:no-repeat; min-height:498px; margin-left: auto; margin-right: auto; margin-top:31px; padding:0; width: 188px; position: relative; height: 100%; } as you see, left, middle and right are have the same size of heigth, which is equal to max of them. and now, what is the question, i want left_ad to have the same heigth too. how can i set the heigth of left_id is equal to left? thanks

    Read the article

  • Extracting pure content / text from HTML Pages by excluding navigation and chrome content

    - by Ankur Gupta
    Hi, I am crawling news websites and want to extract News Title, News Abstract (First Paragraph), etc I plugged into the webkit parser code to easily navigate webpage as a tree. To eliminate navigation and other non news content I take the text version of the article (minus the html tags, webkit provides api for the same). Then I run the diff algorithm comparing various article's text from same website this results in similar text being eliminated. This gives me content minus the common navigation content etc. Despite the above approach I am still getting quite some junk in my final text. This results in incorrect News Abstract being extracted. The error rate is 5 in 10 article i.e. 50%. Error as in Can you Suggest an alternative strategy for extraction of pure content, Would/Can learning Natural Language rocessing help in extracting correct abstract from these articles ? How would you approach the above problem ?. Are these any research papers on the same ?. Regards Ankur Gupta

    Read the article

  • PInvoke or using /clr:pure to compile

    - by Yin Zhu
    I have a set of numerical libraries in C++ and I want to call them interactively in a interpretive language like F# or IronPython. So I have two choices now: Compile the library in native DLL and use PInvoke to call functions in it. Compile the C++ library to .Net dll using visual c++ (/clr:pure compile option). The advantage of 1 is that it is very fast, however there are more work in it, e.g. I cannot PInvoke double pointer (e.g. float **), I must write another wrapper in the C++ library to make the interface friendly to .Net. The advantage of 2 is that I don't need to do know Mashaling strings, arrays, etc. However, the .net dll is slower compared to the native one. What others factors should be considered when choosing between the two?

    Read the article

  • Buttons, hover, text and transitions on pure css3

    - by Mascote Ricardo
    I bought a responsive html5 template to create a website for my band. But I miss a page of tour dates, and would create a unique content, simple and quick to load on any device. I have the idea ready, something like buttons (months) to change on hover and when clicked, shows the dates and cities, all with transitions and fadein / fadeout. (pure css3) to better explain and make me understand, follows an image I created in photoshop. http://img51.imageshack.us/img51/1542/l17u.jpg can someone give me a help, idea or tag to search the web, I thank you too!

    Read the article

  • Pure virtual destructor in interface

    - by ALOR
    Hello all. Here is my problem. I'm making C++ dll, which extensively relies on instance object exports. So i return my actual instances as a pointers to interface through some exported factory method. Interfaces i use are purely virtual, to avoid linking problame. So i need a pure virtual destructor too, and i implemented one (with empty body, as i googled it). All compiles perfectly well, except... I can't see, if the actual destructors are called or not - because when i added some std::cout << "hello destructor"; i never get to see it. I have some explicit "delete obj", that's not the problem. Am i missing something? Is there another way to delete my object through interface?

    Read the article

  • dealing with IO vs pure code in haskell

    - by Drakosha
    I'm writing a shell script (my 1st non-example in haskell) which is supposed to list a directory, get every file size, do some string manipulation (pure code) and then rename some files. I'm not sure what i'm doing wrong, so 2 questions: How should i arrange the code in such program? I have a specific issue, i get the following error, what am i doing wrong? error: Couldn't match expected type [FilePath]' against inferred typeIO [FilePath]' In the second argument of mapM', namelyfileNames' In a stmt of a 'do' expression: files <- (mapM getFileNameAndSize fileNames) In the expression: do { fileNames <- getDirectoryContents; files <- (mapM getFileNameAndSize fileNames); sortBy cmpFilesBySize files } code: getFileNameAndSize fname = do (fname, (withFile fname ReadMode hFileSize)) getFilesWithSizes = do fileNames <- getDirectoryContents files <- (mapM getFileNameAndSize fileNames) sortBy cmpFilesBySize files

    Read the article

  • Python: Slicing a list into n nearly-equal-length partitions

    - by Drew
    I'm looking for a fast, clean, pythonic way to divide a list into exactly n nearly-equal partitions. partition([1,2,3,4,5],5)->[[1],[2],[3],[4],[5]] partition([1,2,3,4,5],2)->[[1,2],[3,4,5]] (or [[1,2,3],[4,5]]) partition([1,2,3,4,5],3)->[[1,2],[3,4],[5]] (there are other ways to slice this one too) There are several answers in here http://stackoverflow.com/questions/1335392/iteration-over-list-slices that run very close to what I want, except they are focused on the size of the list, and I care about the number of the lists (some of them also pad with None). These are trivially converted, obviously, but I'm looking for a best practice. Similarly, people have pointed out great solutions here http://stackoverflow.com/questions/312443/how-do-you-split-a-list-into-evenly-sized-chunks-in-python for a very similar problem, but I'm more interested in the number of partitions than the specific size, as long as it's within 1. Again, this is trivially convertible, but I'm looking for a best practice.

    Read the article

  • Algorithm for finding the smallest power of two that's greater or equal to a given value

    - by Boyan
    I need to find the smallest power of two that's greater or equal to a given value. So far, I have this: int value = 3221; // 3221 is just an example, could be any number int result = 1; while (result < value) result <<= 1; It works fine, but feels kind of naive. Is there a better algorithm for that problem? EDIT. There were some nice Assembler suggestions, so I'm adding those tags to the question.

    Read the article

  • Why does `intval(1990)` equal `1989`?

    - by George Edison
    Boy, this one is really weird. I expect the following code to print 1990, but it prints 1989! $val = '$19.9'; $val = preg_replace('/[^\d.]/','',$val); $val = intval($val * 100); echo $val; Why on earth is this happening? Edit: and this code: $val = '$19.9'; $val = preg_replace('/[^\d.]/','',$val); echo $val . "<br>"; $val = $val * 100; echo $val . "<br>"; $val = intval($val); echo $val; Prints: 19.9 1990 1989 Why does intval(1990) equal 1989???

    Read the article

  • Different results when applying function to equal values

    - by Johannes Stiehler
    I'm just digging a bit into Haskell and I started by trying to compute the Phi-Coefficient of two words in a text. However, I ran into some very strange behaviour that I cannot explain. After stripping everything down, I ended up with this code to reproduce the problem: let sumTup = (sumTuples°concat) frequencyLists let sumFixTup = (138, 136, 17, 204) putStrLn (show ((138, 136, 17, 204) == sumTup)) putStrLn (show (phi sumTup)) putStrLn (show (phi sumFixTup)) This outputs: True NaN 0.4574206676616167 So although the sumTupand sumFixTup show as equal, they behave differently when passed to phi. The definition of phi is: phi (a, b, c, d) = let dividend = fromIntegral(a * d - b * c) divisor = sqrt(fromIntegral((a + b) * (c + d) * (a + c) * (b + d))) in dividend / divisor

    Read the article

  • Nothing = String.Empty (Why are these equal?)

    - by Ek0nomik
    I find it very puzzling that null equals String.Empty in VB.NET. There must be an explanation for it that I'm not understanding. Somehow, when the equality of String.Empty (which has an object type of string) is tested against Nothing (which has no type) the test returns true. It just seems like a turn around in logic to me. In SQL if I were to compare an empty char or varchar against a null value, the test wouldn't return true. A null value is not the same as an empty string in this case. Yet in VB.NET they are equal. I'd love it if someone could provide a good explanation around this.

    Read the article

  • The data types text and nvarchar are incompatible in the equal to operator

    - by metro
    Hi there. this is my code ProductController.cs public ActionResult Details(string id) { product productx = productDB.products.Single(pr => pr.Product1 == id); return View(productx); } Details.aspx <td> <%-- : Html.ActionLink("Edit", "Edit", new { id=item.Id }) % --> <%: Html.ActionLink("Details", "Details", new { id = item.Product1 })%> </td> this is what im using to list some products from a sql database, each product have a link to a Details page to show more informations about it what Im trying is to only put the product label in that link to let it show something like www.mysite.com\products\battery (not the id) I've imagined this should work, but it throw an The data types text and nvarchar are incompatible in the equal to operator. error and neither (pr => pr.Product1.Equals(id)); works the error is clear and Im asking how should I do to make it work this way ? thanks

    Read the article

  • Splitting a double vector into equal parts

    - by Cosmin
    Greetings, Any input on a way to divide a std::vector into two equal parts ? I need to find the smallest possible difference between |part1 - part2|. This is how I'm doing it now, but from what you can probably tell it will yield a non-optimal split in some cases. auto mid = std::find_if(prim, ultim, [&](double temp) -> bool { if(tempsum >= sum) return true; tempsum += temp; sum -= temp; return false; }); The vector is sorted, highest to lowest, values can indeed appear twice. I'm not expecting part1 and part2 to have the same numbers of elements, but sum(part1) should be as close as possible to sum(part2) For example if we would have { 2.4, 0.12, 1.26, 0.51, 0.70 }, the best split would be { 2.4, 0.12 } and { 1.26, 0.51, 0.70 }. If it helps, I'm trying to achieve the splitting algorithm for the Shannon Fano encoding. Any input is appreciated, thanks!

    Read the article

  • Postpone email when domains equal

    - by michalzuber
    HI. For a client i'm developing 4 different email agents for his web portal. I need to send a lot of emails to clients (couple of thousands in the future) which are stored in a database. Sending is fine, but I would like to work out a PHP script which sends emails, but also stores the previous email domain and if they equal than postpone that email for sending later to prevent spam filters. I'm going to load that script with cron and I already set_time_limit(0); Big thanks for replies with ideas ;)

    Read the article

  • Set the output of a function equal to a variable

    - by ryno
    How would i set the output of a custom php function to a variable? The function is: function getRandomColor1() { global $cols; $num_cols = count($cols); $rand = array_rand($cols); $rand_col = $cols[$rand]; echo $rand_col; unset($cols[$rand]); } How would i set getRandomColor1 equal to $RandomColor1? I need it to be a variable so I can use it in css like: #boxone1 { height: 150px; width: 150px; background: <?=$RandomColor1?>; float: left; } If its not possible to set it as a variable, how else could i put the output of the function into css?

    Read the article

  • Split Entire Hash Range Into n Equal Ranges

    - by noxtion
    Hello. I am looking to take a hash range (md5 or sha1) and split it into n equal ranges. For example, if n=5, the entire hash range would be split by 5 so that there would be a uniform distribution of key ranges. I would like n=1 to be from the beginning of the hash range to 1/5, 2 from 1/2 to 2/5, etc all the way to the end. I am new to hashing and a little bit unsure of where I could start on solving this for a project. Any help you could give would be great.

    Read the article

  • Error comparing hash to hashed mysql password (output values are equal)

    - by Charlie
    Im trying to compare a hashed password value in a mysql database with the hashed value of an inputted password from a login form. However, when I compare the two values it says they aren't equal. I removed the salt to simply, and then tested what the outputs were and got the same values $password1 = $_POST['password']; $hash = hash('sha256', $password1); ...connect to database, etc... $query = "SELECT * FROM users WHERE username = '$username1'"; $result = mysql_query($query); $userData = mysql_fetch_array($result); if($hash != $userData['password']) //incorrect password { echo $hash."|".$userData['password']; die(); } ...other code... Sample output: 7816ee6a140526f02289471d87a7c4f9602d55c38303a0ba62dcd747a1f50361| 7816ee6a140526f02289471d87a7c4f9602d55c38303a0ba62dcd747a1f50361 Any thoughts?

    Read the article

  • between syntax, are there any equal function

    - by gcc
    /* char **mainp=malloc(sizeof(char *)*2); mainp[0]=malloc(sizeof(char)*300); mainp[1]=malloc(sizeof(char )*300); */ *I have some input about propositional calculus *After calculating some math funtion-removing paranthesis-changing"&" with ","-replacing "|" with"," I have >> (1) P,-Q,Q,-R is stored in mainp[0] R,A,P,B,F is stored in mainp[1] *My question is: Between comma , I have want to compare two pointer array. If there is any equal two or more functions(Q,-R is function representation) ,function which you will show me how to write must return int. According to example (1),function will return 1 (I expect like that) /*I have som thought://which function should I have use:*/ in for loop if( strspn(mainp[0][i])==1 ) increment d; continue; or in for loop srtcmp(mainp[0][i],mainp[1]);

    Read the article

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