FpGUI
   HOME

TheInfoList



OR:

fpGUI, the Free Pascal GUI toolkit, is a
cross-platform Within computing, cross-platform software (also called multi-platform software, platform-agnostic software, or platform-independent software) is computer software that is designed to work in several Computing platform, computing platforms. Some ...
graphical user interface toolkit developed by Graeme Geldenhuys. fpGUI is
open source Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use and view the source code, design documents, or content of the product. The open source model is a decentrali ...
and
free software Free software, libre software, libreware sometimes known as freedom-respecting software is computer software distributed open-source license, under terms that allow users to run the software for any purpose as well as to study, change, distribut ...
, licensed under a Modified LGPL license. The toolkit has been implemented using the
Free Pascal Free Pascal Compiler (FPC) is a compiler for the closely related programming-language dialects Pascal and Object Pascal. It is free software released under the GNU General Public License, witexception clausesthat allow static linking against it ...
compiler, meaning it is written in the
Object Pascal Object Pascal is an extension to the programming language Pascal (programming language), Pascal that provides object-oriented programming (OOP) features such as Class (computer programming), classes and Method (computer programming), methods. T ...
language. fpGUI consists only of graphical widgets or components, and a cross-platform 2D drawing library. It doesn't implement database layers, 3D graphics, XML parsers etc. It also doesn't rely on any huge third party libraries like GTK or Qt. All the extras come straight from what is available with the Free Pascal Component Library (FCL) which comes standard with the
Free Pascal Free Pascal Compiler (FPC) is a compiler for the closely related programming-language dialects Pascal and Object Pascal. It is free software released under the GNU General Public License, witexception clausesthat allow static linking against it ...
compiler.


History

The first version of fpGUI was written by Sebastian Günther back in 2000. The project was then abandoned in 2002. fpGUI was a successor to an earlier OO GTK wrapper, fpGTK, and was pretty much a fresh start to allow multiple (backend) widgetsets, most notably win32. The toolkit was used for some internal FPC tooling (e.g. the fpdoc editor), but there were still a lot of open issues before the toolkit could be truly useful and used in real life applications by end-users. Most of these tools where migrated to the maturing
Lazarus Lazarus may refer to: People *Lazarus (name), a surname and a given name * Lazarus of Bethany, a Biblical figure described as being raised from the dead by Jesus * Lazarus, a Biblical figure from the parable of the Rich man and Lazarus * Lazar ...
in the 2004-2006 timeframe. Graeme Geldenhuys revived the toolkit in mid-2006 where Sebastian left off. He continued developing the toolkit for the next year. Merging three sub-projects (fpGFX, fpIMG and fpGUI) into a single project fpGUI. Graeme extended the number of components and amount of backend graphics layer, and improved the overall toolkit. The supported platforms at that stage was
Linux Linux ( ) is a family of open source Unix-like operating systems based on the Linux kernel, an kernel (operating system), operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically package manager, pac ...
and
FreeBSD FreeBSD is a free-software Unix-like operating system descended from the Berkeley Software Distribution (BSD). The first version was released in 1993 developed from 386BSD, one of the first fully functional and free Unix clones on affordable ...
via
X11 The X Window System (X11, or simply X) is a windowing system for bitmap displays, common on Unix-like operating systems. X originated as part of Project Athena at Massachusetts Institute of Technology (MIT) in 1984. The X protocol has been at ...
and Microsoft Windows via GDI. After a few months Felipe Monteiro de Carvalho joined the development team adding support for Windows Mobile devices and extending the graphics support and design. Felipe also started working on Mac OS X support via Carbon. At the beginning of June 2007 Graeme found some major design issues in the source base. This prevented fpGUI from being truly useful in real applications. After numerous prototypes the fpGUI project was completely rewritten. Past experience helped a lot and new design ideas were implemented. The code base ended up being much simpler with a cleaner design. One of the major changes was that all widgets were now based on a multi-handle (windowed) design. Each widget now has a window handle. Other GUI toolkits that follow a similar design are
GTK GTK (formerly GIMP ToolKit and GTK+) is a free software cross-platform widget toolkit for creating graphical user interfaces (GUIs). It is licensed under the terms of the GNU Lesser General Public License, allowing both Free software, free and ...
, Xt and
FLTK Fast Light Toolkit (FLTK) is a cross-platform widget (graphical control element) library for graphical user interfaces (GUIs), developed by Bill Spitzak and others. Made to accommodate 3D graphics programming, it has an interface to OpenGL, but ...
to name a few. GUI toolkits that follow the opposite design are toolkits like the latest Qt and MSEgui.


Example program

The following program shows a single window with a "Quit" button in the bottom right. On the canvas (background) of the window it paints all the standard built-in images used with fpGUI. program stdimglist; uses Classes, SysUtils, fpg_base, fpg_main, fpg_form, fpg_imgfmt_bmp, fpg_button; type TMainForm = class(TfpgForm) private btnClose: TfpgButton; procedure btnCloseClick(Sender: TObject); protected procedure HandlePaint; override; public constructor Create(aowner: TComponent); override; procedure AfterCreate; override; end; procedure TMainForm.AfterCreate; begin SetPosition(100,100,700,500); WindowTitle := 'fpGUI Standard Image Listing'; // Place button in bottom right corner. btnClose := CreateButton(self, Width-90, Height-35, 75, 'Quit', @btnCloseClick); btnClose.ImageName := 'stdimg.quit'; btnClose.Anchors := nRight, anBottom end; procedure TMainForm.btnCloseClick(Sender: TObject); begin Close; end; procedure TMainForm.HandlePaint; var n: integer; x: TfpgCoord; y: TfpgCoord; sl: TStringList; img: TfpgImage; begin Canvas.BeginDraw; // begin double buffering inherited HandlePaint; sl := TStringList.Create; x := 8; y := 8; fpgImages.ListImages(sl); for n := 0 to sl.Count-1 do begin Canvas.DrawString(x, y, sl ':'); img := TfpgImage(sl.Objects ; if img <> nil then Canvas.DrawImage(x+130, y, img); inc(y, img.Height+8); if y > Height-32 then // largest images are 32 in height begin inc(x, 200); y := 8; end; end; Canvas.EndDraw; sl.Free; end; constructor TMainForm.Create(aowner: TComponent); begin inherited Create(aowner); (* PRIOR TO v1.4: // Place button in bottom right corner. btnClose := CreateButton(self, Width-90, Height-35, 75, 'Quit', @btnCloseClick); btnClose.ImageName := 'stdimg.quit'; btnClose.Anchors := nRight, anBottom *) end; procedure MainProc; var frm : TMainForm; begin fpgApplication.Initialize; frm := TMainForm.Create(nil); try frm.Show; fpgApplication.Run; finally frm.Free; end; end; begin MainProc; end. Here is a screenshot of the above program when run under Linux.


Licensing

fpGUI is statically linked into programs and is licensed using a modified version of LGPL specially designed to allow static linking to proprietary programs. The only code you need to make available are any changes you made to the fpGUI toolkit - nothing more.


Software written with fpGUI


Master Maths
br />Used in a computer-based training system. As well as a basic accounting and administration package for franchisees. * A Visual Form Designer which is now included as part of fpGUI. It allows the developer to create user interfaces at a much faster pace.
Unimesur and various tools
br/>Written by Jean-Marc, the Unimesur program allows to convert measurements of flows of liquids and gases, between mass and volume units. All results were verified for the exactness of the conversion factors. * fpGUI DocView
An INF help file viewer that currently works on Windows,Unlike old 16-bit IPF .inf/.hlp viewers DocView can be used on 64-bit Windows Linux and FreeBSD. INF is the default help format of fpGUI, and is also the help format used in
OS/2 OS/2 is a Proprietary software, proprietary computer operating system for x86 and PowerPC based personal computers. It was created and initially developed jointly by IBM and Microsoft, under the leadership of IBM software designer Ed Iacobucci, ...
(and also
eComStation eComStation or eCS is an operating system based on OS/2 Warp for the 32-bit x86 architecture. It was originally developed by Serenity Systems and Mensys BV under license from IBM. It includes additional applications, and support for new hardwa ...
and
ArcaOS ArcaOS is a Proprietary software, proprietary operating system based on OS/2, developed and marketed by Arca Noae, LLC under license from IBM. It was first released in 2017 and builds on OS/2 Warp 4.52 by adding support for new hardware, fixing ...
).
Free Pascal Testing Framework
br/>A cross-platform unit testing framework with a Console and GUI test runner.


See also

*
Lazarus (software) Lazarus is a cross-platform, integrated development environment (IDE) for rapid application development (RAD) using the Free Pascal compiler. Its goal is to provide an easy-to-use development environment for developing with the Object Pascal la ...
*
Widget toolkit A widget toolkit, widget library, GUI toolkit, or UX library is a library (computing), library or a collection of libraries containing a set of graphical control elements (called ''widgets'') used to construct the graphical user interface (GUI) of ...
* Qt *
wxWidgets wxWidgets (formerly wxWindows) is a widget toolkit and tools library for creating graphical user interfaces (GUIs) for cross-platform applications. wxWidgets enables a program's GUI code to compile and run on several computer platforms with no s ...
*
GTK+ GTK (formerly GIMP ToolKit and GTK+) is a free software cross-platform widget toolkit for creating graphical user interfaces (GUIs). It is licensed under the terms of the GNU Lesser General Public License, allowing both free and proprietary s ...
* FOX toolkit *
FLTK Fast Light Toolkit (FLTK) is a cross-platform widget (graphical control element) library for graphical user interfaces (GUIs), developed by Bill Spitzak and others. Made to accommodate 3D graphics programming, it has an interface to OpenGL, but ...


References


External links


official fpGUI Toolkit website

fpGUI's SourceForge.net project page

Free Pascal compiler

Lazarus IDE
{{DEFAULTSORT:Fpgui Free computer libraries Free Pascal Free software programmed in Pascal Pascal (programming language) libraries Programming tools for Windows Software using the GNU Lesser General Public License Widget toolkits X-based libraries Pascal (programming language) software