Search Results

Search found 1369 results on 55 pages for 'jc martin'.

Page 41/55 | < Previous Page | 37 38 39 40 41 42 43 44 45 46 47 48  | Next Page >

  • wpf: How to keep an image stay in its original size?

    - by Martin Luo
    hi, guys! i have a problem about the image display in wpf. here's my code <Button HorizontalAlignment="Left" Grid.Column="1" Grid.Row="5" Margin="0,5"> <Button.Content> <StackPanel Orientation="Horizontal" Margin="10,0"> <Image Source="/images/user_add.png" Stretch="None" HorizontalAlignment="Center" VerticalAlignment="Center" Width="24" Height="24" /> <TextBlock Text="??" /> </StackPanel> </Button.Content> </Button> i hava the image with original size 32*32, but when i ran the above code, the image will stretch to fill all the space, beyond its original size, and i also set the "Stretch" property to "None", but it seems that it doesn't work. so, how can i fix this problem? thank u~~~!

    Read the article

  • git, SSH_ASKPASS on windows

    - by Martin Schreiber
    I am writing a graphical git frontend for Linux and Windows (MSEgit) based on MSEide+MSEgui. MSEgit has an internal console window which communicates with git by pipes. On Linux it uses a PTY so SSH asks for key unlocking passwords on the PTY. On Windows I wrote a small password entry application and set the SSH_ASKPASS environment variable accordingly. SSH calls the password application if git is started with CreateProcess() dwCreationFlags DETACHED_PROCESS set but the password entry window will not be focused, its taskbar icon flashes instead. SSH does not run the password application if FreeConsole() is called to be sure that there is no attached console to MSEgit and git is started without DETACHED_PROCESS but CREATE_NO_WINDOW instead. I assume a Windows equivalent of POSIX setsid() should be called. How can I force SSH to use SSH_ASKPASS without the DETACHED_PROCESS flag? If this is not possible, how can I ensure that the password entry window is focused?

    Read the article

  • How to declare class attributes in swift, just like UITableViewCell reuse identifiers?

    - by martin
    I am trying to declare a reuse identifier associated to a UITableView subclass in swift. From my understanding I would like to declare an class stored property (not an instance one) so i have access via: MyCustomTableCell.ReuseIdentifer. Here is what I was trying: class MyCustomTableViewCell : UITableViewCell { class let ReuseIdentifier = "MyCustomTableViewCellReuseIdentifier" } The compiler mentions that class attributes are not supported yet. How to declare such kind of constants associated to a class type in a clean way?

    Read the article

  • Git: Make one branch exactly like another

    - by G. Martin
    I am relatively new to Git, and I'm still not very comfortable with it. Right now, I'm looking for the command/options/magic that can make the current branch look like another branch; that is, to merge them, but when a conflict arises, to always choose the difference in the branch that is being merged into the current one. My situation is thus; I have an stable(ish) application on the "master" branch. I also have another branch, called "feature". I basically want to make changes/additions/deletions to feature until I like the new feature I'm working on. Once I feel it is ready, I want to make the master branch look identical to the feature branch. I know this probably isn't a best practice, but as I said, I'm new to Git. I plan on learning how to do more complicated things in the future, but for now, this is all I need. Thanks, SO!

    Read the article

  • How to change security configutarion in IE8 for Intranet pages, such that Javascript can close a Win

    - by Martín Fixman
    I am developing a system that uses a little Internet page as a front-end for the whole program. Since I need to use ActiveX (sigh), the page must work on Internet Explorer. However, after some actions have been done the page needs to close itself. Using window.close() on Javascript it works, but before closing it prompts the user if it wants to close the Window. The ideal would be that it closes automatically. Is there any way to make IE8 (changing an option on the browser, not a code-only solution) not to prompt before closing the Window?

    Read the article

  • How do I set a static bool in another app domain?

    - by Martin
    How do I programatically set the value of a static boolean in another app domain? I'm testing an application where I need to change a bool value. Problem is that the bool value exists as a static instance on a type hosted in another app domain. (I'm doing this for test purposes, it won't be used in production code)

    Read the article

  • How do I take a copy of my working copy to share with others?

    - by Martin
    I did a ton of changes to our code and before I commit, I would like a friend to review. Is there a way with SVN to take a copy of my working copy (to bundle everything in a package) and apply the changes I have made so far to another machines without having to commit? In the past, with another source control system, I was able to do the following to "pack" and "unpack" my changes. Is there anything similar with SVN? sourcecontrol.exe pack myChanges.pack sourcecontrol.exe apply myChanges.pack Thanks!

    Read the article

  • Adding to a bit array

    - by Martin
    In my program, I am using BitArrays to represent 160 bit numbers. I want to be able to add, subtract, increment and decrement these numbers, what is the algorithm for doing this? At the moment I'm not interested in multiplication and division, but I might be in the future so bonus points for that. I'm implementing in C#, but pseudocode is fine if you're not familiar with the language

    Read the article

  • SQL Server float datatype

    - by Martin Smith
    The documentation for SQL Server Float says Approximate-number data types for use with floating point numeric data. Floating point data is approximate; therefore, not all values in the data type range can be represented exactly. Which is what I expected it to say. If that is the case though why does the following return 'Yes' in SQL Server DECLARE @D float DECLARE @E float set @D = 0.1 set @E = 0.5 IF ((@D + @D + @D + @D +@D) = @E) BEGIN PRINT 'YES' END ELSE BEGIN PRINT 'NO' END but the equivalent C++ program returns "No"? #include <iostream> using namespace std; int main() { float d = 0.1F; float e = 0.5F; if((d+d+d+d+d) == e) { cout << "Yes"; } else { cout << "No"; } }

    Read the article

  • Class properties vs NSArray / NSDictionary

    - by Frank Martin
    I want a custom class object to hold data and have somehow the feeling that creating about 80 properties is not the best way of doing it. Most of the properties would be bool values, so i'm thinking about creating Arrays (keys / values) or (probably better) a NSDictionary attached to the object for holding the data. Does that make sense or should i stay with the properties? Extra: Are there general pros and cons for the different approaches? And what keywords / concepts do i have to search for to find discussions about that somehow general question? Thanks in advance

    Read the article

  • Firefox engine library

    - by martin.malek
    Hi, I'm now using AxWebBrowser component to get DOM from web page and find used styles on each element. Unfortunatelly this is not working perfectly and some elements doesn't return correct data. I'm thinking about if it's possible to use engine from firefox? Is there some dll library I can use, navigate to the page and go throw DOM of the page?

    Read the article

  • Failure when adding images to a thumbnail gallery

    - by Martin KS
    morning all, I've been browsing around trying to work out what I've done wrong when trying to add a thumbnail to a gallery view, but can't work out what on earth it might be. I'm trying to use the following code to stick a thumbnail onto a blank view: UIImageView *any = [[UIImageView alloc] initWithFrame:CGRectMake(a,b,70,60)]; any.image = [UIImage imageNamed:selectedThumbPath]; any.tag = 0; [self.view addSubview:any]; In the above example: a = 165 b = 150 selectedThumbPath = the full path to a thumbnail ie. /users/Cleverbum/library etc I'm pulling my hair out, there are no error messages, and no clues as to why it's not drawing anything. What's worse is that this is one of the only parts of the code i've not changed!

    Read the article

  • What is the best way to write faster on Vim using a non-english keyboard?

    - by Martín Fixman
    I usually use Vim, and its great for the ability to do faster some actions than other editors. However, since I live in Argentina I have a Latin American keyboard, that makes everything in Vim pretty slower (to write / to search, I must press Shift+7). Since I don't want to be changing Keyboard layouts all the time (and its pretty difficult to get used to pressing symbols as in an English keyboard), I was wondering if there was a vim plugin (of .vimrc file) that may be useful for international users. Just for the sake of it, here's how the Latin American keyboard is laid out: By the way, I would love to go and buy an English keyboard, but unfortunately I use a Laptop.

    Read the article

  • prefix routing cakephp

    - by nick martin
    Hello, Just a quick one.. I am unsure how to prevent a prefix, for example if I am in domain.com/admin/orders or domain.com/user/order which are admin_ and user_ actions and the navigation menu contains links to pages displays (controller pages action display, **) when they are clicked on they are automatically prefixed by the current prefix. How can I set in the router file to redirect wildcards prefixes (ie. /pages/)?

    Read the article

  • HashMap as return value from Java method in R?

    - by Martin
    Hi, is it possible to return a HashMap to R with the rJava extension of R? E.g. I have a method in Java, which returns a HashMap and I want this HashMap use in R. I tried: .jcall(javaObj, "Ljava/util/HashMap", "getDbInfoMap") This doesn't work. Do I have to put everything into a String[], that I want to pass to R from Java? Or is there another possibility? Any help/info on this would be greatly appreciated.

    Read the article

  • ondevicemotion in Chrome desktop returns true

    - by Martin Klasson
    I am using a "shake" function from github - and it has a detection that is browser-based javascript. //feature detect this.hasDeviceMotion = 'ondevicemotion' in window; This though yields true even on Chrome on OS X. It feels strange, since I am not willing to shake my monitor on my desktop. Safari on OS X gives me "false" in return when testing. I have searched but not been able to find out why Chrome decided to take this path. It bugs me. Is there a better way to make this detection? Not all "mobile devices" has shake as well.. or does not let the browser have that capability, as it does not seem to work in windows phones.

    Read the article

  • Propagate properties to parent control C#

    - by Martin Ch
    Is there any way how to propagate properties from child control into parent - so I can access property like - Parent.Property1 instead of Parent.Child.Property1 ? I cant use inheritance - my parent cant be extended child type - its inherited from different class. Also I dont wanna add code for each property from child to parent like: public object Property1 { get{ return Child.Property1; } set{ ChildProperty1 = value; } } Maybe using reflection - something like this? public PropertyInfo[] Properties { get{ return Child.GetType().GetProperties(); } set{ Child.GetType().GetProperties().SetValue() = value.GetValue()} } Thanks

    Read the article

  • XSL(like) declarative language as MVC view over strongtyped model?

    - by Martin Kool
    As a huge XSL fan, I am very happy to use xsl as the view in our proprietary MVC framework on ASP.NET. Objects in the model are serialized under the hood using .NET's xml serializer, and we use quite atomic xsl templates to declare how each object or property should transform. For example: <xsl:template match="/Article"> <html> <body> <div class="article"> <xsl:apply-templates /> </div> </body> </html> </xsl:template> <xsl:template match="Article/Title"> <h1> <xsl:apply-templates /> </h1> </xsl:template> <xsl:template match="@*|text()"> <xsl:copy /> </xsl:template> This mechanism allows us to quickly override default matching templates, like having a template matching on the last item in a list, or the selected one, etc. Also, xsl extension objects in .NET allow us just the bit of extra grip that we need. Common shared templates can be split up and included. However Even though I can ignore the verbosity downside of xsl (because Visual Studio schema intellisense + snippets really is slick, praise to the VS-team), the downside of not having intellisense over strongtyped objects in the model is really something that's bugging me. I've seen ASP.NET MVC + user controls in action and really starting to love it, but I wonder; Is there a way of getting some sort of intellisense over XML that we're iterating over, or do you know of a language that offers the freedom and declarativeness of XSL but has the strongtype/intellisense benefits of say webforms/usercontrols/asp.net.mvc-view? (I probably know the answer: "no", and I'll find myself using Phil Haack's utterly cool mvc shizzle soon...)

    Read the article

  • Accessing HTML DOM elements from javascript using `.childNodes`

    - by Martin
    I'm wondering about the .childNodes property, I have the code below, and for some reason I get 18 children, while 6 are HTMLInputElements as expected, and the rest are undefined. What is this about? Is there an efficient way to iterate over the input elements? <html> <head> <script> window.onload = function(e){ form = document.getElementById('myForm'); alert(form.childNodes.length); for(i=0; i<form.childNodes.length; i++){ alert(form[i]); } } </script> </head> <body> <form id='myForm' action="haha" method="post"> Name: <input type="text" id="fnameAdd" name="name" /><br /> Phone1: <input type="text" id="phone1Add" name="phone1" /><br /> Phone2: <input type="text" id="phone2Add" name="phone2" /><br /> E-Mail: <input type="text" id="emailAdd" name="email" /><br /> Address: <input type="text" id="addressAdd" name="address" /><br /> <input type="submit" value="Save" /> </body> </html>

    Read the article

  • Is there a way to have one project build another in Visual Studio?

    - by Martin Neal
    We are finally getting a source control system in place at work and I've been in charge of setting it up. I've read that it's usually good practice to not include binaries in source control so I haven't. However, we have two all-purpose utility projects (each in their own solution) that generate utility .dll's which are included in almost all of our other projects (all each in their own separate solutions). We add references to the utility dll from our projects. I would like to have our solutions set up in such a way that if the reference dll isn't built, the solution will build the dll for itself, much in the same way a make file checks for its dependencies and builds them when they're out of date or missing. I'm new to build processes with VS so try to keep the answers simple. Any links to general build process overview tutorials would be great too. Googleing for VS references returns a bunch of how-to add references links which is not exactly what I want.

    Read the article

< Previous Page | 37 38 39 40 41 42 43 44 45 46 47 48  | Next Page >