gui

C#: Centering controls within a form in .NET (Winforms)?

I'm trying to center a fixed size control within a form. Out of interest, is there a non-idiotic way of doing this? What I really want is something analogous to the text-align css property. At the moment, I'm setting the padding property of the surrounding form to a suitable size and setting the Dock property of the control to fill. ...

Moving items between two list boxes. What do you call this type of form?

What do you call a form with two list boxes and buttons to move the list box items from one to the other? I've always called it a "switch list". ...

Can one executable be both a console and GUI app?

I'm wanting to make a c# program that can be run as a CLI or GUI app depending on what flags are passed to it. Can this be done? I have found these related questions but they don't exactly cover my situation: How to write to the console in a GUI application How do I get console output in C++ with a Windows program? ...

What are your best Swing design patterns and tips?

I'm writing a GUI for an application using Swing, and in the interests of code maintenance and readability, I want to follow a consistent pattern throughout the whole system. Most of the articles and books (or at least book sections) that I've read appear to provide plenty of examples on how to create and arrange various components, but...

Creating GUI application completely in QtScript, what is your opinion?

Since QT license change is announced I started to take a look at the QT framework. It looks nice, but I don't like having to use C++. I know there are different bindings for various languages, but QtScript seems most interesting to me. Is it possible to use QtScript to code complete GUI application (with help from UI designer, of course...

Progress bar not updating during operation

in my python program to upload a file to the internet, im using a GTK progress bar to show the upload progress. But the problems that im facing is that the progress bar does not show any activity until the upload is complete, and then it abruptly indicates upload complete. im using pycurl to make the http requests...my question is - do...

Is there a simple way to do GUI input for a relational database?

I'm building a student rostering application for a friend and I'm just about done except for the GUI. I'm writing it in wxpython but I'm not sure how to proceed with the input fields because it is a relational database. Is there a simple way to do this? ...

Qt and VC++ 6.0 IDE?

First of all I was wondering if I should use Qt and Windows together. If so should I use VC++ 6.0 IDE or another one? ...

BackgroundWorker Problem c#

Hi , i have got CopyFile and Directory project.But when i started to copy Gui is freezing.I cant do anything file copying.So i found my solution at BackgroundWorker Component.But i got a problem with this component too.There are 3 radio button and command button.When i clicked command button its checking if radiobutton1 checked or else r...

How to delete buttonGroup in netbeans 6.5

Hi, I'm new to netbeans I played around with matisse gui editor and would like to delete a buttonGroup with no reference. I tried the refactor/safe delete action but no way to do so!! That so bad. Is there a trick or do I have to re-start everything? 2.By the way I find it so crazy not to be able to edit the generated grey source cod...

How does one reproduce the inset text style when drawing text with Mac OS X Cocoa?

I'm talking about the groove style of the text on focussed title bars, or safari's bookmarks bar for example. Is there an easy way to reproduce this style when using: [string drawAtPoint:... withAttributes:...]; ...

When should I add a GUI?

I write many scripts at home and on the job. Most of the time the scripts get used only a few times to accomplish their chosen task and then are never used again. However, sometimes I write a script to do something more complicated, something that requires user input. It is at this point that I usually agonize over whether to implemen...

Java - Handle multiple events with one function?

First of all, I am a complete Java NOOB. I want to handle multiple button presses with one function, and do certain things depending on which button was clicked. I am using Netbeans, and I added an event with a binding function. That function is sent an ActionEvent by default. How do I get the object that was clicked in order to trigge...

Why is GUI code so computationally expensive?

All you Stackoverflowers, I was wondering why GUI code is responsible for sucking away many, many cpu cycles. In principle, the graphical rendering is far less complex than Doom (although most corporate GUIs will introduce lots of window dressing). The event handling layer is also seemingly a heavy cost, however, it seems that a well-...

Is there a generic term for "GUI-Element"?

The question may sound silly and it might not even be a programming question. At least it's a programming meta question (about talking about programming). What I want to know is if there is a generic, widely understood term for GUI elements. I have programmed so many GUI toolkits, I couldn't tell if Windows-only programmers know what th...

Custom widget shapes in SWT

I'm trying to work out how to make SWT widgets (e.g. Label, Frame) be some shape other than rectangular. I've made a custom shaped main window using the setRegion() method. Now I would like the widgets in the window to follow the same shape. I've tried using the setRegion() method on the widgets themselves (they inherit it) but nothing ...

Keeping the GUI separate

I have a program that (amongst other things) has a command line interface that lets the user enter strings, which will then be sent over the network. The problem is that I'm not sure how to connect the events, which are generated deep inside the GUI, to the network interface. Suppose for instance that my GUI class hierarchy looks like th...

Button image too far from top of button; too close to bottom of button

I'm working on a Windows Form in VB.NET 2005 and I would like to have some buttons with images (I'm talking about the plain, vanilla System.Windows.Forms.Button). I have everything set up the way I want it but the images are displaying too low on the button, such that the bottom of the icon is almost right on the bottom of the button an...

Detecting a single mouse click in MFC

In MFC a double-mouse click event triggers the following sequence of messages WM_LBUTTONDOWN WM_LBUTTONUP WM_LBUTTONDBCLK WM_LBUTTONUP So responding to the WM_LBUTTONDBCLK message allows you to detect a double-click. But if I just want to detect a single-click how to I distinguish it? But just looking at the WM_LBUTTONUP message isn...

Fastest way to create a Java message dialog (swing/awt/other)?

I'm creating a Java application that will do some processing then needs to display a message to give the user feedback. However, it appears to be incredibly slow - taking over two seconds to return. I stripped the source down to the apparent culprit, and here is the code used: package SwingPlay; import javax.swing.JFrame; public cla...