search for: fxmainwindow

Displaying 17 results from an estimated 17 matches for "fxmainwindow".

Did you mean: cmainwindow
2009 Jun 23
9
Learning FXRuby please help!
...know why. My puts command says that the window is shown, but it''s not displayed. Also, it seems to me that there should be an easier way to get text on a screen in response to pressing a button. Any hints? Thanks! Marlene require ''fox16'' include Fox class Lookup < FXMainWindow def initialize(app) super(app, "Lookup window", :width=>400, :height=>600, :opts => DECOR_ALL|LAYOUT_FILL_X|LAYOUT_FILL_Y) bframe = FXHorizontalFrame.new(self, :opts => LAYOUT_FILL_X) hearButton = FXButton.new(bframe, "Do you hear me?") yesWindo...
2005 Apr 05
0
Connecting messages to methods
Hi all. I''m trying to write a subclass of FXMainWindow which has several methods to dispatch events. The class looks like this: -- require "fox12" require "fox12/responder" include Fox class Window < FXMainWindow include Responder ID_SELF, ID_BTN = enum(FXMainWindow::ID_LAST, 2) def initialize(a, title) super(a, tit...
2008 Feb 08
2
Dynamic resize of drawing canvas and FXImage
How can I use the drawing canvas and its off-screen image buffer, say FXImage, to dynamically resize or have its width and height attributes changed in reply to user interaction with the main window (FXMainWindow)? It seems that whem I put initial values to W and H of the canvas or FXImage, they remain with its initial values no matter what I do whem resizing the main window. -- Ranieri Barros Teixeira Ci?ncia da Computa??o - Faculdade de Computa??o - Universidade Federal do Par? (UFPA) http://rubyxchar...
2005 Dec 22
1
FxTopWindow problem
...w, and call create on it. This all seems to work well, but I was unhappy with the look and feel of the FXDialog. I basically wanted something that looked like a real window, with minimize, restore, and close boxes in the upper right, and windowy ( if that''s a word ) border. I tried using FXMainWindow, FXTopWindow, and FXWindow, but I am again faced with my arch nemesis of error messages: "This application has requested the Runtime to terminate it in an unusual way. Please contact the application''s support team for more information. >Exit code: 3" I have gotten this is...
2006 Feb 13
1
FXDialogBox and the destroy and close methods
Hi everyone! I constructed a FXDialogBox instance. When I call the TXTopWindow?s close() method or the FXWindow?s destroy() method, the FXMainWindow becomes unavailable for use. It becomes inoperative. What can I do to solve this problem? Very thanks, Waiting for answer. ----------------------------------------- Ronaldo Rodrigues Ferreira rrferreira at inf.ufrgs.br Universidade Federal do Rio Grande do Sul Instituto de Inform?ti...
2008 Oct 27
2
Using BUTTON_TOOLBAR
...t any frame, but they do not change appearance when the cursor moves over them. I''m running Ruby 1.8.6 (2007-09-24 patchlevel 111) [i386-mswin32] on Microsoft Windows Vista [Version 6.0.6001]. Here''s my code: require ''fox16'' include Fox class MainWindow < FXMainWindow def initialize(app) super(app, "Toolbar Example", :width => 485, :height => 300) tool_bar_shell = FXToolBarShell.new(self) top_dock_site = FXDockSite.new(self, :opts => LAYOUT_FILL_X|LAYOUT_SIDE_TOP) tool_bar = FXToolBar.new(top_dock_site, tool_bar_s...
2005 Feb 18
2
Fixed column widths in FXTable?
...e one click installer (FXRuby-1.2.3-ruby182.exe). fxversion() reports "1.2.13" from the irb command prompt. The machine has a Pentium 4 and 256mb ram. ------------------------------------------------------------------------- require "fox12" include Fox class TestWindow < FXMainWindow def initialize(app) super(app, "MyTest", nil, nil, DECOR_ALL, 0, 0, 600, 400, 0, 0) table = FXTable.new(self, nil, 0, LAYOUT_FILL_X|LAYOUT_FILL_Y) table.setTableSize(50, 3) (0...50).each do |r| table.setItemText(r, 0, "#{r},0") table.setItem...
2005 Aug 05
3
Popup menu attached to a FXTreeItem
Hi, I''m using FXRuby 1.0 on Windows. I''d like to display a popup menu after a right click on a tree item, I cannot make it work : #-------------------- root = FXTreeList.new(parent, 1, self, 0) pop = FXMenuPane.new(parent) expandCmd = FXMenuCommand.new(pop, "Expand", nil, app) expandCmd.connect(SEL_COMMAND) { root.currentItem.expanded=(true) }
2005 Feb 18
5
FXTable segfaults after multiple setTableSize calls
...il, let me know that -- maybe it is some other problem on this machine I''ll have to track down (display driver?). Thanks for your help. David Peoples ------------------------------------------------------------------------- require "fox12" include Fox class TestWindow < FXMainWindow TABLE_SIZE = 10_000 def initialize(app) super(app, "MyTest", nil, nil, DECOR_ALL, 0, 0, 600, 400, 0, 0) mainFrame = FXVerticalFrame.new(self, LAYOUT_FILL_X|LAYOUT_FILL_Y) @table = FXTable.new(mainFrame, nil, 0, LAYOUT_FILL_X|LAYOUT_FILL_Y) goButton = FXButton.n...
2006 Mar 07
5
FXProgressDialog trouble
...nding ID_ACCEPT to the dialog with the same results. I''ve seen some other threads on this list (and others) with the same issue, with no solution... can someone point me to an example of successfully using this dialog? Thanks.. Maurice ------------------------- code snippet: -- in my FXMainWindow: progress = FXProgressDialog.new(self, "Upload Progress", "Starting upload") th = Thread.new { # this does the upload, and calls progress.increment and sets progress.message OpenomyUploader.upload(dir, tags, progress) progress.destroy } progress.execute -------------- nex...
2008 Nov 11
3
FXTextField and number of digits after decimal point
Hello, Here''s the context: I read a number either pure integer or float with eventually up to 12 digits after the decimal point from a YAML file. The number is injected into a FXTextField with the following code: @value_sel = FXDataTarget.new(@value.to_s) @value_value = FXTextField.new(@matrix_mem_value, 20, at value_sel, :opts =>TEXTFIELD_NORMAL|JUSTIFY_RIGHT,
2006 Apr 10
1
Display an arrow, or transparent image colors
...arrow, pointing from to the right, (3) a FXDial. I figured I can display the Arrow using a .png image containing a red arrow on transparent background, loading that image using FXPNGIcon, and display it in FXImageFrame. Example code: require "fox14" include Fox app = FXApp.new window = FXMainWindow.new(app, "Demo") window.place(PLACEMENT_SCREEN) hframe = FXHorizontalFrame.new(window) file_display = FXTextField.new(hframe, 40, nil, 0, LAYOUT_CENTER_Y) file_display.text = "SoundFile.wav" arrow_image = File.open("ArrowShortRightRedT.png", "rb") {|f| F...
2005 Mar 23
2
FXListBox size behavior?
...ax: 314-739-4972 ----------------------------------------------------- #!/usr/bin/env ruby # tested using FXRuby 1.2.5 and Ruby 1.8.2 (One-click installer # on Windows XP) require ''fox12'' include Fox application = FXApp.new("listboxtest", "FoxTest") main = FXMainWindow.new(application, "FXListBox test", nil, nil, DECOR_ALL, 0, 0, 400, 200) myListBox = FXListBox.new(main) myListBox.appendItem("a very long example") myListBox.appendItem("short") myListBox.appendItem("longer") myListBox.appendItem("even longer") my...
2005 Dec 01
1
Can''t add text to FXCanvas
...n an unusual way. Please contact the application''s support team for more information. >Exit code: 3 I also get this error if I try to set the font of the FXCanvas or the FXDCWindow. I have a short sample program that shows this problem. Thanks for any help. class PlotterWindow < FXMainWindow def initialize(app) # Invoke base class initialize first super(app, "Plotter", nil, nil, DECOR_ALL, 0, 0, 500, 700) @color4 = FXColor::LightBlue1 @color5 = FXColor::Blue @font = FXFont.new(app,"times",14) dumpFontDesc("Initial Font", at font.g...
2010 Apr 09
2
Problem detecting keypresses in FXTable
I''m using an RXTable in my application and I would like to be able to select a row and then press the Delete key to delete the selected row. This does not seem to work, however, as apparently keypresses are not initially recognized. In my FXTable derived class I have: connect(SEL_KEYRELEASE) do |sender, selector, event| puts "code = #{''%X'' %
2008 Sep 06
0
Tab control using FXRuby
...he next fields are displayed. Thanks ============================================== #!/usr/bin/env ruby # zestaddr2.rb # Generated by RubyFXGen.rb Ver 0.9a on :Mon Sep 01 17:20:31 +1000 2008 # plus added code to setup scroller require ''fox16'' include Fox class MainWindow < FXMainWindow def initialize(app) super( app, ''Zest Address Entry'') self.width = 422 self.height = 250 amain= FXVerticalFrame.new(self,LAYOUT_NORMAL|LAYOUT_FILL_X|LAYOUT_FILL_Y) main = FXScrollWindow.new(amain, LAYOUT_FILL_X|LAYOUT_FILL_Y) addr= FXMatrix.new(main, 2,MATRIX_BY_COL...
2008 Apr 14
3
Copy-paste between FXTable and FXTextfield
...ere is a good chance the "copy" command has got a bug with the object FXTable. Is that correct? Here is my test code: ---------------------------------------------- #!/usr/bin/ruby require ''rubygems'' require ''fox16'' include Fox class MyWindow < FXMainWindow def initialize(app) super(app, "Window", nil, nil, DECOR_ALL, 0, 0, 600, 350) # Menu bar stretched along the top of the main window menubar = FXMenuBar.new(self, LAYOUT_SIDE_TOP|LAYOUT_FILL_X) # File menu filemenu = FXMenuPane.new(self) FXMenuTitle.new(...