Sign in Join
Wiki copytemporary

Feature Ideas: what changed

Revision 1 to 2. Removed lines have a minus sign; added lines have a plus sign.

OldNewLine
11> **Warning:** This page is intended to **collect ideas** for features that **could** be included in FPC/Lazarus. Putting an idea here does **not mean** it **WILL** be put into FPC/Lazarus. It's just a place to gather ideas. Think of this as more of a wishlist.
22
33If it is clear who is going to implement the feature, for example, because you have a patch or somebody on the mailing list volunteered to implement it, then it can be added to the [FPC/Lazarus Bugtracker](http://bugs.freepascal.org/), so it can be tracked and scheduled for a release.
44
55If you really want to see a feature implemented urgently, have a look at [[Bounties]] to pay for development.
66
77Tags: Wish, Wishes, Wishlist
88
99# IDE
1010
1111Features that could be included in the IDE
1212
1313## An Integrated IDE
1414
1515(Partly) done in 0.9.29: see [[Anchor Docking]]
1616
1717> **Warning:** There are known bugs in the docking implementation. The Lazarus developers are aware of these and will be working on them if time permits. If you want to help speed this up by providing code, please get in touch on the Lazarus mailing list
1818
1919There are too many windows in the IDE. The more features you use the more they pile up on your desktop and become hidden behind other windows. This is confusing for the newbie and otherwise a mess. Docking windows as found in some IDEs might seem to give flexibility however in practice it is a two dimensional solution. You accidentally undock a window and have it hanging on your mouse while you try to put it back where it was. It would be better to use conventional splitters and tab controls to put it all together into a logical layout.
2020
2121- Associated windows should be converted to Frames and then placed on a single form or tab page on the main form
2222- 1\. There should be a Welcome Page having new project wizards, a list of recent projects, help and resources
2323- 2\. A Development tab containing sub tabs for code and for form design
2424
2525:* a. Code tab including Code Explorer, Source Editor and Project Manager
2626
2727:* b. Form design tab including Object Inspector, Form designer and Component Palette
2828
2929- 3 Debug tab containing the Debug windows as Frames.
3030
3131- 4 since an integrated IDE has less screen real estate, swapping in and out windows need to be easier.
3232
3333:* a. Probably a view concept is needed (different layout in debug then in normal (debug)). Maybe differentiate dependning on the F12 state (designer visible) too.
3434
3535:* b. Big missing feature is the ability to let tabs page in from the side (a tab system to the left and right from the screen, ideal for process manager). When such tab loses focus, it pops back.
3636
3737## Auto-generated database form
3838
3939If you have set up a TSQLQuery, it would be nice to be able to let the IDE autogenerate a from with appropriate controls for all fields. --BigChimp 16:39, 8 August 2014 (CEST)
4040
4141## Easier Dragging & Dropping
4242
4343### Ideas that have been implemented
4444
45-Done in 0.9.29: Options / Form editor / Ask name on create <s>pool: after you add a component at Form, what is your next action? Editing Name/Caption in OI. Would be nice having OI focused and a key field like Name/Caption/Text selected. It would be very intuitive just having to type after dropping the component.</s>
45+Done in 0.9.29: Options / Form editor / Ask name on create pool: after you add a component at Form, what is your next action? Editing Name/Caption in OI. Would be nice having OI focused and a key field like Name/Caption/Text selected. It would be very intuitive just having to type after dropping the component.
4646
4747## Common
4848
4949- enable menu access through access keys like under windows (i hate mouse sessions :o)
5050
5151example: \<alt\>-\<f\> for file menu. **Question: what operating system/widget set are you talking about?**
5252
5353### Ideas that have been implemented
5454
55-- (Done in 1.1) <s>Open files in the same folder as the current tab editor, like SCite does, it's a bit annoying to navigate from folder to folder every time you need open a file related to the one we are editing at the moment.</s>
55+- (Done in 1.1) Open files in the same folder as the current tab editor, like SCite does, it's a bit annoying to navigate from folder to folder every time you need open a file related to the one we are editing at the moment.
5656
5757## Source Editor
5858
5959- Multiple splitting (and close the split) the editor to horizontal and vertical views like with VIM, so I can do split for example Vertically, and inside do a split for Horizontal editor. And we can close each split by right click on the movable splitter and select it from a menu item.
6060
6161- VIM keyboard support - require implementation of a command line like that can accept keyboards like with the VIM text editor.
6262
6363
6464A good example is Qt Creator: you press Alt+V+V and get into FakeVim mode, where most vim commands work
6565
6666Question: what do you mean by keyboard? Another keyboard layout? Different shortcuts keys? Shortcut keys can already be defined via the Tools menu
6767
6868- Multi linguistic spell checkers for strings and comments, using aspell, hspell, ispell etc... (aspell and hspell already have binding for FPC)
6969
7070### Ideas that have been implemented
7171
72-- (Done in 0.9.27) <s>When focusing/selecting one BEGIN the respective END should be in RED to show where it really ends.</s>
72+- (Done in 0.9.27) When focusing/selecting one BEGIN the respective END should be in RED to show where it really ends.
7373
74-- (Done in 0.9.29) <s> Movable tabs, so we can place tabs as we wish instead of keeping them where they where opened. </s>
74+- (Done in 0.9.29) Movable tabs, so we can place tabs as we wish instead of keeping them where they where opened.
7575
76-- (Done in 0.9.27) <s> Ability to have a way to fold code arbitrary by using comments with special chars such as </s>
76+- (Done in 0.9.27) Ability to have a way to fold code arbitrary by using comments with special chars such as
7777
7878`some code {% /* } <-- start folding `\
7979` more code`\
8080` ...`\
8181` ...`\
8282`and more code {% */ } <-- stop folding `
8383
84-- Done: if you click on an error message, the cursor jumps to the code line in question and highlights it.<s>Color code on errors with special underline or some type of color that the user can select/change that will help to locate where the problem is (not instead of the error message that exists today).</s>
84+- Done: if you click on an error message, the cursor jumps to the code line in question and highlights it.Color code on errors with special underline or some type of color that the user can select/change that will help to locate where the problem is (not instead of the error message that exists today).
8585
86-- Done: see below <s>Ability to keep the string mark (that added to 0.9.27) of a word/selected string as permanent with a toggle of a menu item/key/toolbar or something</s>
86+- Done: see below Ability to keep the string mark (that added to 0.9.27) of a word/selected string as permanent with a toggle of a menu item/key/toolbar or something
8787
8888
8989QUESTION: Does that refer to the "highlight all occurrences" of "word under caret"/"current selection"?
9090
9191That is possible (try alt-M)
9292
93-- (Done: Lazarus 1.0+: context-sensitive help is included with at least the windows installer. See [[Installing Help in the IDE]] <s>Inline help for a command/reserve word that the mouse cursor/keyboard caret are under that word (not instead of the tooltip that exists today when the mouse is hover the command/variable).</s>
93+- (Done: Lazarus 1.0+: context-sensitive help is included with at least the windows installer. See [[Installing Help in the IDE]] Inline help for a command/reserve word that the mouse cursor/keyboard caret are under that word (not instead of the tooltip that exists today when the mouse is hover the command/variable).
9494
95-- (Done) <s>When pressing on CTRL on a file/variable/type etc.. that we are trying to load, it will place a tooltip telling what is going to be opened (the file + the line number)</s> (The information is shown when hovering over the variable)
95+- (Done) When pressing on CTRL on a file/variable/type etc.. that we are trying to load, it will place a tooltip telling what is going to be opened (the file + the line number) (The information is shown when hovering over the variable)
9696
97-- Done in 0.9.29 <s>Ability to save and load color scheme for syntax highlight.</s>
97+- Done in 0.9.29 Ability to save and load color scheme for syntax highlight.
9898
99-- Done (present in at least 1.2): see Edit/Find in Files which has a replace option <s>Within the "Edit" menu, add an option called "Replace in files...", which allow find and replace text in all the units of the application, doing it at once.</s>
99+- Done (present in at least 1.2): see Edit/Find in Files which has a replace option Within the "Edit" menu, add an option called "Replace in files...", which allow find and replace text in all the units of the application, doing it at once.
100100
101101### Improvement of the menu and toolbars
102102
103103- to allow end user customization
104104- to obtain more styled menu (similar as Shagrouni xp-menu style)
105105
106106## Integrated and Working Debugger
107107
108108Debugging from inside the IDE can be a frustrating process. I believe this is a combination of GDB being more C/C++ centric, or because it is a more generalized standalone debugger. Either way, I think the ultimate solution is to write a custom debugger for use with FPC and Lazarus IDE. This way it will be possible for the debugger to support ALL Object Pascal and Lazarus IDE requirements, or maybe even be compiled into the Lazarus IDE itself. GDB does support Object Pascal, but not nearly at the level it does with C/C++.
109109
110110An IDE without sufficient debugging support is a hard sell to would-be contributors or Delphi converts. This might also have contributed to some of the negative comments received in the Delphi non-technical newsgroup. Make no mistake, I love the many unique IDE features Lazarus has to offer - it beats Delphi IDE by far.
111111
112112Apart from the standard Lazarus debugging solution using gdb there are multiplle custom written debuggers, partly or completely implemented in Object Pascal:
113113
114114- [[FpGdbmiDebugger]]: uses gdb but also adds Pascal code. In development, experimental; included with Lazarus
115115- **[[FpDebug]]**: Located at components\lazdebuggers\lazdebuggerfp\LazDebuggerFp.lkp Currently support Linux and Windows
116116- **[Duby](http://sourceforge.net/projects/duby/)**: A research project on SourceForge.net.
117117- **[fpdebug (fork of duby)](https://github.com/graemeg/fpdebug)**: It's a fork of Duby with some further development work. I didn't know about the name conflict with the Lazarus one though. The joys of the FP* prefix. :)
118118
119119Please try out these projects and contribute if you can.
120120
121121## Object Inspector
122122
123123### Search field
124124
125125add a "search" text box at the top or bottom (preferred, maybe user settable) of Object Inspector to be able to search for a name or value (maybe with right click menu checkable options on whether Name or Value or both are searched) in the properties/events list
126126
127127Question: What about sub properties?
128128
129129### Recent page
130130
131131add a "Recent" tab to Object Inspector apart from the "Favorites" one, would be more useful than the Favorites one since it's automatic (would keep all properties/events that have been edited \[fields that have either been changed or ENTER was pressed to CONFIRM/REset their current value - focus lost events shouldn't be considered editing if value of property/event field didn't change\])
132132
133133Question: How are items removed from the list?
134134
135135### Not registered component classes
136136
137137Add a field in the object inspector to allow specifying the real class that will be instantiated, with that will allow to uses derived classes without remake/link the IDE, of course the new fields for the real class will not be available to edit in designer. An example: We place a TEdit in a form, but we want to use a derived class we made that add a new field/property/method to TEdit and we will use that new field/property/method programming but in design time it's enough to work with TEdit, actually there is an option to change the class but only to another one that's already linked on the IDE.
138138
139139> **Note:** The class must be registered. This is needed for streaming and RTTI. If you don't want to register the real class, then register a fake class. It would be possible to create an artificial derived class from a registered component class on the fly. This has nothing to do with the OI. A dialog to manage all artificial classes must be implemented and a menu item must be added somewhere.
140140
141141## Refactoring
142142
143143### Global Variable/Method renaming
144144
145-<s>Proper renaming (as in if I rename a field in an object it can change everything that uses it but NOT other stuff that happens to have the same name) -Plugwash</s>
145+Proper renaming (as in if I rename a field in an object it can change everything that uses it but NOT other stuff that happens to have the same name) -Plugwash
146146
147147
148148Already implemented: See Source Editor -\> popup menu -\> refactoring -\> rename identifier
149149
150150### Parameter Renaming in Methods
151151
152152adding a parameter to a method (and updating everything that uses it) -Plugwash
153153
154154
155155How should that work? What should the IDE/codetools put as parameter at the places?
156156
157157
158158You specify that when you ask for the parameter to be added. Plugwash 05:09, 30 September 2006 (CEST)
159159
160160For example, you add a parameter "b: boolean". The method is used a 100 times.
161161
162162- Possibility 1: You add a default parameter too. No change to the using methods is needed.
163163- Possibility 2: You press compile and the compiler will jump to every occurence and you can decide, what to do.
164164- Possibility 3: A new dialog is added to the IDE, where you can specify to insert a ",false" at every occurence.
165165- Possibility 4: ?
166166
167167Do you have 3 in mind or 4?
168168
169169### Parameter reordering
170170
171171like Delphi. A dialog to add, remove, reorder parameters of a function, method, property.
172172
173173### Improvement of the IDE like GExperts does for Delphi
174174
175-- Done: see Project/Publish project <s>Backup tool...</s>
175+- Done: see Project/Publish project Backup tool...
176176- Tab : provision to set Tab spacing
177177
178178
179179Question: please indicate what you specifically miss in Tools/Editor/General/Tab and Indent
180180
181181- Rename Components (where it is possible too, to fill some properties in this moment. f.e. Button: Caption, Width, Height, Action)
182182
183183## I have a dream of components : Jedi
184184
185185Sure I switch immediately from Delphi to Lazarus.
186186
187187- The Jedi components are a mix of OS dependant, Borland dependant and architecture specific code. I doubt these will ever work on anything but windows/x86. (and maybe win64 with a bit shoehorning). Example: To use a string routine in the strings unit of JCL, you have to fix like 12 units, some of which poke around in the Borland specific debug code. And then you haven't even reached the units of the JVCL, besides this there is a [[licensing]] problem. Marcov 18:27, 4 October 2008 (CEST)
188188- A lot of Jedi code has been implemented in FPC already. Question: do you need more? What components exactly? --BigChimp 15:16, 28 March 2014 (CET)
189189
190190## Code completion
191191
192192### Create/Free objects
193193
194194Declare an object myObj:TMyClass into a TForm class an type some Ctrl-Shift-Key, then the IDE adds a line myObj:=TMyClass.Create in FormCreate and myObj.Free in FormDestroy. -Rednaxel
195195
196196### Add list properties
197197
198198Declaring an indexed property like 'property Items\[i: integer\]: TAType' and using this feature (Ctrl-Shift-Key, Menu), should popup a dialog to setup some parameters and then it should add a private variable fItems: TFPList; (or 'array of' or TList or ^AType), create code in the constructor, destroy code in the destructor and access methods GetItems, SetItems.
199199
200200## Visual Form Inheritance
201201
202202VFI (Visual From Inheritance) works in Lazarus but there are some missing features:
203203
204204- When ancestor and descendant are open in the IDE and a property of the ancestor is changed, then change the descendant too.
205205
206206## Conditional Compiler Options
207207
208208See [[Conditional Compiler Options]].
209209
210210## Help
211211
212212### A small tutorial for Object Oriented Programming
213213
214214I wish to have in Lazarus as in Eclipse in the Help menu a Tutorial for Object Oriented Programming.
215215
216216- This is a good idea, but I think a **offline** help browser is first required. Lucky for you, I already implemented such a beast, called [DocView](http://sourceforge.net/projects/fpgui/files/fpGUI/1.4/). :-) I also have a few old programming manuals around that could contribute to the contents. I know Borland released the OOP chapter what was included in the Turbo Pascal v5.5 & v6 manuals for everybody to use (freely downloadable). So maybe that will be the best place to start. A downloadable copy of the OOP Chapter can be found [here](http://geldenhuys.co.uk/articles/). I also have freely available INF e-books (viewable with DocView) that cover the introduction to Object Pascal and OOP programming (follow [this](http://geldenhuys.co.uk/~graemeg/inf_books/) link) --Ggeldenhuys 13:44, 29 November 2013 (GMT)
217217- Offline help has been included since Lazarus 1.0x with lhelp and the chm format. A help menu item that shows lhelp is included with Laz trunk. Maybe the .inf books could be converted to chm and included with the Lazarus installer --BigChimp 14:21, 30 November 2013 (CET)
218218
219219## Better Macro support by making them easier to find
220220
221221See the feature request [\#14558](http://bugs.freepascal.org/view.php?id=14558) in Mantis. In summary, add a button next to EditBox controls which support macro usage. Clicking the button will display a popup menu with available macros at that level and insert the selected macro into the EditBox at the cursor position.
222222
223223## Copy and Paste Support for a lazy programmer (in properties-editor)
224224
225-<s>Maybe it's by design (because of the same behaviour under win and mac)... but I think, it's a little bit of annoying. When I try to copy the chosen "name" of a component out of proterties-editor by selecting it and ctrl+c, I will not get the text of the name, but the object/component description itself (which is useless, I guess). There is not even a "copy" item in the context-menu. I use very long descriptive names for components (and variables) and it would be nice, to get these unhandy names somehow into the clipboard. KaLi 14:56, 30 June 2010 (CEST)</s>
225+Maybe it's by design (because of the same behaviour under win and mac)... but I think, it's a little bit of annoying. When I try to copy the chosen "name" of a component out of proterties-editor by selecting it and ctrl+c, I will not get the text of the name, but the object/component description itself (which is useless, I guess). There is not even a "copy" item in the context-menu. I use very long descriptive names for components (and variables) and it would be nice, to get these unhandy names somehow into the clipboard. KaLi 14:56, 30 June 2010 (CEST)
226226
227227
228228This seems to work in 0.9.31, both Ctrl+C and via context-menu [Bart](http://wiki.lazarus.freepascal.org/User:Bart)
229229
230230## Code Library Window or Tab
231231
232-<s>It would be great to have a built in location to store all those useful pieces of code. Ones that you have created, or found useful.
232+It would be great to have a built in location to store all those useful pieces of code. Ones that you have created, or found useful.
233233
234234My ideal feature list would be:
235235
236236- Save and Load my personal code
237237- Attach Zip file ( useful for keeping a sample project, showing the code in use).
238238- Ability to Upload Code / zip to central online repository.
239239- Ability to synchronize or select repository code and download to my own code store.
240240- Code could be sectioned into well thought out categories, like Types of controls, Libraries, complete project examples, Tutorials, etc.
241241- A place to show the most recent code submitted by Category.
242242
243243It would also be a good place to help people who need some assistance. I would have the following options:
244244
245245- Option to Ask for help on a control or subject matter.
246246- Notification when a solution is uploaded to the repository.
247-- Maybe a points system rating the assistance given out of 10 ( 1 being not useful, 10 being just what I needed)</s>
247+- Maybe a points system rating the assistance given out of 10 ( 1 being not useful, 10 being just what I needed)
248248
249249
250250The "Code Librarian" third party code library tool is available made by Lazarus forum user taazz. Helping him with incorporating these features (if he wants to) could be the best way of getting this functionality: <http://forum.lazarus.freepascal.org/index.php/topic,22752.0.html> and <https://sourceforge.net/projects/codelibrarian/>
251251
252252## Write and run unit tests from subpackage of project being tested
253253
254254The main idea is to have ability to write and run Unit tests from a subpackage of main project. **Please see [[Feature Ideas/UnitTests]]**
255255
256256# LCL
257257
258258## Components
259259
260260Components that are possible to make that will work across all platforms supported by Lazarus
261261
262262- Do you mean customdrawn components? If so, that is already possible. I think the TStringGrid is a customdrawn component. Alternatively, look at [[fpGUI]] for a completely customdrawn GUI toolkit. --Ggeldenhuys 23:56, 30 September 2009 (CEST)
263263
264264### Visual
265265
266266- The existing **TDBLookupComboBox**, could be greatly enhanced by something like an "**.IsFiltered** property": If true, the control should reduce its list of visible (and hence selectable) values in the dropdown list by filtering the DataField by the current DBLookupComboBox while editing. This means, onChange (resulting in DBLookupComboBox.Text updated to someString) automatically reduces the list to **SELECT lookup_field FROM lookup_table WHERE lookup_field LIKE %'+someString+'%**. A feature like that would greatly enhance the usability of Lazarus made database applications!\
267267 To illustrate this idea, compare other similar projects: [1](https://www.freelancer.com/projects/Delphi/Custom-Delphi-TDBLookupComboBox/) [2](https://www.devexpress.com/Support/Center/Question/Details/B196085/filtering-dataset-of-tcxdblookupcombobox) or [3](https://www.drupal.org/sandbox/jauzah/1748434), or this [screenshot](https://www.drupal.org/files/project-images/select2element_screen.jpg) .
268268
269-- Already implemented [[Add Help to Your Application]]: <s>Help system for apps created by Laz! It is a plugin system. That's why it supports cross-platform help system and using the OS's native help system.</s>
269+- Already implemented [[Add Help to Your Application]]: Help system for apps created by Laz! It is a plugin system. That's why it supports cross-platform help system and using the OS's native help system.
270270
271271- The current LCL TStringGrid is a nice improvement over Delphi's feeble control with the same name. Would be great if it could be improved even more!
272- - <s>Support for data validation event handler, similar to Orpheus grid's OnUserValidation event.</s> *There are many events, for example OnEditingDone, and OnValidateEntry to do this. See [[Grids Reference Page]] and [[Event order]]*
272+ - Support for data validation event handler, similar to Orpheus grid's OnUserValidation event. *There are many events, for example OnEditingDone, and OnValidateEntry to do this. See [[Grids Reference Page]] and [[Event order]]*
273273 - Support for retrieving, displaying, editing and storing data that are stored in an existing memory structure or in a file rather than in grid itself, similar to the Orpheus grid's OnGetCellData and OnGetCellAttributes events. *There is the TTIGrid, that can show TCollection, TList and TFPList of TPersistent. What else do you need? Additionally, you can bind a TBufDataset to a dbgrid...*
274274 - A TImage component wich support transparent winxp alpha 32 bit icon images
275- - <s>Support for RightToLeft BidiMode.</s> Fixed in 0.9.31 according to <http://bugs.freepascal.org/view.php?id=18918>. Bug report tracking all RTL/Bidi: <http://bugs.freepascal.org/view.php?id=19303> If there are still bugs, please report them to the bug tracker.
275+ - Support for RightToLeft BidiMode. Fixed in 0.9.31 according to <http://bugs.freepascal.org/view.php?id=18918>. Bug report tracking all RTL/Bidi: <http://bugs.freepascal.org/view.php?id=19303> If there are still bugs, please report them to the bug tracker.
276276- TTrayIcon
277277 - Add a TImageList property in TTrayIcon to change TrayIcon icon or animate it
278278
279279### NonVisual
280280
281-- Clipboard and <s>TTimer</s> that don't depend on LCL. If you use these in a library or console app, the compiler drags in a lot of unused and unneeded LCL code. If you have multiple DLL's, this code is duplicated in each. Current implementations appear to follow the Delphi design approach, where Clipboard and TTimer have dependencies on the VCL - this probably wasn't necessary.
281+- Clipboard and TTimer that don't depend on LCL. If you use these in a library or console app, the compiler drags in a lot of unused and unneeded LCL code. If you have multiple DLL's, this code is duplicated in each. Current implementations appear to follow the Delphi design approach, where Clipboard and TTimer have dependencies on the VCL - this probably wasn't necessary.
282282 - TfpTimer is a non-LCL timer already available in FPC in unit **fptimer.pp**. Online help is available [here](http://lazarus-ccr.sourceforge.net/docs/fcl/fptimer/index.html). --Ggeldenhuys 14:38, 2 September 2009 (CEST)
283283 - This may be true on Windows, but it´s False for Linux. I recently implemented TTimer for qt interface and the implementation calls Qt API. I think the same applies to Clipboard, since the clipboard depends on the widgetset used too (gtk or qt for example), not only on the operating system. --Sekelsenmat 20:40, 5 Mar 2006 (CET)
284284 - The LCL is a visual component library. None visual components are provided by the FCL.
285285 - Lazarus will only provide components based on the LCL.
286286
287287## PDA Support
288288
289289Something that currently does not exist is a complete multiplatform solution for PDAs. If we can implement this, Lazarus will become the first multiplatform RAD for PDAs ever created. Some devices work with Java, some work with c++ and Qtopia, some work with their particular APIs, there is no single solution currently that can embrace a large portion of PDAs. Application have to be redone for every PDA or simply just run on one of them (what most people do).
290290
291291The LCL implements many things. It is not necessary to implement them all to have a reasonably working Lazarus PDA widgetset. The most important things to be implementeded for PDAs are:
292292
293293- TApplication
294294- TForm
295295- TScreen
296296- TCanvas and painting
297297- Most Events (onClick and OnPaint at least)
298298- Basic widgets like: TButton, TLabel, TEdit, TMemo.
299299- Only minimum necessary LCLIntf functions to make TCanvas work. (GetDC, ReleaseDC, BeginPaint, EndPaint and some painting functions)
300300
301301Others can be easily implemented by people who need them after those are ready.
302302
303303Here is a list of some PDAs and the status of their support on Free Pascal / Lazarus:
304304
305305- Windows CE - The compiler already works really well cross compiling for Windows CE. The [[Windows CE Interface]] is under implementation.
306306- Symbian OS - Possible for their ARM devices. Requires first adding a new Runtime Library for this OS to the Compiler. This OS has it's own API. There are open source projects for python and c to work on Symbian OS, so Free Pascal should work as well when a RTL is written.
307307- Qtopia - For Zaurus and other linux-based PDAs. This is much easier now that basic Qt4 widgetset has being implemented, because Qtopia is very similar to Qt4. Some magick on the bindings is expected to make the same widgetset code to run for both Qtopia and Qt4.
308308- Java - Some handheld devices, specially phones, only support java bytecode. May seam a little odd, but there is a Pascal Compiler capable of compiling the source into a jar and then into bytecode. It's name is Midlet Pascal <http://www.midletpascal.com/> It may be possible to develop a similar technology that adds a java bytecode target for Free Pascal. Some people already start porting midletpascal to delphi <http://forum.boolean.name/attachment.php?attachmentid=7975&d=1255392966>, follow instructions on <http://www.pascalgamedevelopment.com/forum/index.php?topic=5466.0> to access it.
309309- Palm OS - PalmOS 5 Garnet support requires that first the 68k compiler is working (runs on ARM processor with a kind of emulation) and then a RTL for palmos needs to be written. Only Free Pascal 1.0 supports 68k, this wasn't updated and the new compiler 2.0 doesn't support it yet (work in progress by [[fpc:User:Chain-Q]]), so will be a problem.
310310
311311PalmOS 6 Cobalt is fully arm, so it only requires a rtl, but it has zero devices working on it currently and won't be on the market until 2007 at least.
312312
313313Other compilers that support this target: [Pascal & Palm Compiler](http://www.ppcompiler.org) and [HsPascal](http://hspascal.fihl.net/). Unfortunately those compilers are not open source, so we can't use their code, we need to implement PalmOS RTL from zero.
314314
315315## More Interfaces
316316
317-- Cocoa - <s>Requires that first OpenSTEP bindings are created for Free Pascal.</s> Cocoa interface support has been started; see [[Cocoa Interface]]
317+- Cocoa - Requires that first OpenSTEP bindings are created for Free Pascal. Cocoa interface support has been started; see [[Cocoa Interface]]
318318- BeAPI - interface for Haiku, ZetaOS and BeOS. There is no powerful RAD on this OS.
319319 - Bindings to the BeAPI has been started - though not part of the Lazarus project. Have a look at SourceForge [befpc](http://befpc.sourceforge.net/) project.
320320- [SDL](http://www.libsdl.org) - something like what was done in [Pixel Image Editor](http://www.kanzelsberger.com/pixel/).
321321- MacApp 2.0 - For 68k-based Mac computers. MacApp was Apple Computer's primary object oriented application framework for the Mac OS for much of the 1990s. First released in 1985, it is arguably the first such system to be widely used, notably on a microcomputer platform. Microsoft's MFC and Borland's OWL were both based directly on MacApp concepts. This framework was completely written on Object Pascal, so it should integrate really nicely with Free Pascal and Lazarus. When Apple moved to PowerPC it also dropped Object Pascal support, but that's another story. A emulator for 68k-Mac can be easely set up with [BasiliskII](http://basilisk.cebix.net/). There is also a project called MacApp2PPC that upgraded MacApp pascal code to run on Power PCs.
322322- OS/2 native - Free Pascal works well with OS/2, so this should be quite possible.
323-- <s>Solaris - OpenSolaris versions exist and it's quite similar to Linux so why not ?</s> For information on the Solaris port of Lazarus, see: [[Lazarus on Solaris]]
323+- Solaris - OpenSolaris versions exist and it's quite similar to Linux so why not ? For information on the Solaris port of Lazarus, see: [[Lazarus on Solaris]]
324324- Web Interface - Application compiles to an embedded HTTP Server who serves forms in ajax pages (or compiles it to an Apache Module), like Intraweb in Delphi. Discussion in <http://www.lazarus.freepascal.org/index.php?name=PNphpBB2&file=viewtopic&t=2489>
325-- Already implemented: <s>[fpGUI](http://fpgui.sourceforge.net/) - A widget set written in Free Pascal without any large library requirements. fpGUI talks directly to the underlying graphics library and is very easy to port to new platforms. Currently it supports Linux, ARM-Linux, FreeBSD, Windows and WinCE.</s> - Under development here: [[fpGUI Interface]]
325+- Already implemented: [fpGUI](http://fpgui.sourceforge.net/) - A widget set written in Free Pascal without any large library requirements. fpGUI talks directly to the underlying graphics library and is very easy to port to new platforms. Currently it supports Linux, ARM-Linux, FreeBSD, Windows and WinCE. - Under development here: [[fpGUI Interface]]
326326
327327### improved EventQueue
328328
329329- [[Lazarus improved Event Queue]]
330330
331331### Lua
332332
333333- Support for Lua interfacing. (Binary modules?)
334334 - What is Lua interfacing? Is it a graphical widgetset? What is the difference between what you want and is supplied by the lua units of fpc: <http://svn.freepascal.org/svn/fpc/trunk/packages/lua/>
335335 - Perhaps the poster wanted to use the Lua scripting language to access the LCL widgetset. Had a quick look at the FPC lua package mentioned above: no readme, no test, no demo, so not easy to see what that package does/can do. Perhaps it can be used as-is to do what the poster wants; in that case, some additional samples/documentation may be handy. BigChimp, September 2012
336336
337337# Visual Improvements
338338
339339## An idea for a splash screen
340340
341-<figure>
342-<img src="splash_logo2_.png‎" title="splash_logo2_.png‎" />
343-<figcaption>splash_logo2_.png‎</figcaption>
344-</figure>
341+![](/wiki-images/e/ea/Splash_logo2_.png%E2%80%8E)
345342
346343The font for "write once..." is DejaVue Serif Condensed, for "Lazarus" is Phantom, and for "object pascal" is Tahoma.
347344
348345If you want to change the splash logo on Windows, in your main Lazarus installation folder find "images" folder and there find "splash_logo.bat". Then edit and run it or replace "splash_logo.png" and run "splash_logo.bat".
349346
350347### critique
351348
352349- as if people's desktops are not already cluttered to the max... not desirable
353350
354351# FPC
355352
356353## Per-type Byte Alignment
357354
358355A means to align variables and records in a unit is already possible with compiler directives, but is somewhat messy and might cause conflicts in some situations. What I propose is an addition to the Free Pascal syntax that forces all variables of a defined type to be aligned to a particular boundary. e.g.
359356
360357``` pascal
361358 type
362359 AlignedDouble = Double align 16;
363360
364361 type
365362 TVector4f = packed record
366363 X, Y, Z, W: Single;
367364 end align 16;
368365
369366 type
370367 TVector4fArray = array of TVector4f align 32;
371368 { tighter restrictions than TVector4f, so it's okay. Note that this should probably align Var[0] to a 32-byte boundary, not necessarily Var as a whole }
372369```
373370
374371Such aligned types are useful and even necessary for when working with SSE and AVX, where significant speed gains can be achieved with aligned data (and some operations require it).
375372
376373Apparently Delphi supports something like this already, but it isn't well-documented.
377374
378375### Nuances
379376
380377- The exact syntax.
381378- Cross-platform support. Do all platforms support memory alignment?
382379- Exact error messages or behaviour if you specify a non-power of 2 alignment.
383380- What happens if you try to typecast an unaligned variable to an aligned type? (Aligned to unaligned should be fine)
384381- What happens if you try to typecast a pointer to an unaligned type to a pointer to an aligned type?
385382- What happens if you, say, declare a type aligned to 16 bytes, and then declare another type that is equal to it but is only aligned to 8 bytes?
386383- What happens if you, say, declare a type aligned to 16 bytes, then use it as a field in a record type, aligned or otherwise?
387384
388385CuriousKit ([[User talk:CuriousKit|talk]]) 18:28, 5 December 2017 (CET)
389386
390387## "vectorcall;" modifier for Win32 and Win64
391388
392389This function modifier is the only unique modifier for Win64 (although it can be used in Win32 too), introduced by Microsoft at the behest of game developers who wish to reduce the overhead of passing vectors and the like into subroutines. The basic details are the same as the regular Win64 calling convention, but attempt to vectorise certain record types and pass them in their entirety through a single XMM register (something which is already possible in Linux64 sometimes). Details can be found here: <https://msdn.microsoft.com/en-us/library/dn375768.aspx>
393390
394391This may require the byte alignment feature described above.
395392
396393
397394vectorcall is implemented in (the upcoming) fpc 3.2 for the win64 platform. Bart
398395
399396### Nuances
400397
401398- What happens if it is used on a platform other than Win32 or Win64? Does a compiler error occur or is it ignored with a warning?
402399
403400CuriousKit ([[User talk:CuriousKit|talk]]) 23:04, 5 December 2017 (CET)
404401
405402- - It is ignored with a warning. Bart ([[User talk:Bart|talk]]) 17:43, 20 December 2022 (CET)
406403
407404- As an example of prior art I think Vector Pascal[1](https://sourceforge.net/projects/vectorpascalcom/) is noteworthy. MarkMLl ([[User talk:MarkMLl|talk]]) 09:12, 6 December 2017 (CET)
408405
409406## "default"-value in a proc or function call
410407
411408- There is a limitation in the freepascal-Syntax where you can not depend on the default-parameter lefthand from an explicit parameter. I suggest a possibility where you can say "default" in a function-call, and set other parameters at the same time.
412409
413410``` pascal
414411program DefaultParameter;
415412
416413{$mode objfpc}{$H+}
417414
418415type
419416 Pilots = (Charles, Amelia, Belly, Louis);
420417
421418procedure Fly(Pilot: Pilots = Belly; Copilot: Pilots = Charles);
422419begin
423420 if (Pilot=Copilot) then
424421 halt(1);
425422end;
426423
427424begin
428425 Fly; // we fly with Belly+Charles
429426 Fly(); // we fly with Belly+Charles
430427 Fly(Amelia); // we fly with Amelia+Charles
431428 Fly(Louis, Belly);
432429
433430 // The following "default" is my Feature Idea
434431 // │
435432 // v
436433 Fly(default, Amelia); // we fly with Belly+Amelia
437434end.
438435```
439436
440437### Critique
441438
442439- If such a feature should exist, wouldn't it be more straightforward to simply not specify anything before the comma? (i.e. "Fly(, Amelia);") CuriousKit ([[User talk:CuriousKit|talk]]) 14:50, 7 December 2017 (CET)
443440
444441## "pure;" function directive
445442
446443I propose a new directive keyword that can be specified for functions, named **pure**. Its intention is to act as a hint to the compiler that the function is fully self-contained, has no side-effects (although the compiler will actually check if this is the case) and is guaranteed to return the same output for a given input. An example would be the Int function, which returns the input value with the fractional part stripped off, and nothing else.
447444
448445So what would be the advantage of a function being 'pure'? With a pure function, if the input values are constants, then the output(s) will also be constants, hence they can be pre-calculated during compilation and the function call completely replaced with an assignment, offering a massive speed boost and providing a sort of general-purpose means of doing what some internal compiler routines do in regards to replacing calls with static values.
449446
450447There are potentially two ways that the compiler can determine if a function is pure:
451448
452449- Perform deep analysis of the pre-compiled assembly language, almost like an emulator (platform-dependent, but will allow pure assembler routines to be considered for function purity, which may be beneficial for operations such as ROL, ROR, BSF and BSR).
453450- Run the subroutine's source code through PascalScript (largely platform-independent), and if unresolved reference errors occur, then the function can be considered impure.
454451
455452In this case, the **pure** keyword gives a hint to the compiler as to which procedures to check for purity, so it doesn't waste a potentially long time on routines that the programmer already knows are impure.
456453
457454If a function is marked as **pure** but it turns out not to be, the compiler throws a warning much like what happens if it's marked as **inline**, but something makes it an invalid candidate. The following paradigms would make a function a non-eligible candidate:
458455
459456- Reading from or writing to external memory (including static and global variables)
460457- Reading from or writing to I/O
461458- Contains **var** parameters (since, by definition, they cannot be a constant)
462459- Dereferencing a pointer (which also means object methods cannot be made pure, including **constructor** and **destructor** since, by definition, they allocate and deallocate memory related to object instantiation. I don't think class methods can be pure either) - the only exception to this are **out** parameters, since their type and size are tightly controlled and the dereferencing is effectively hidden from the programmer anyway.
463460- Allocating or deallocating memory
464461- Obtaining the address of something (using the @ operator)
465462- Calling another function (unless that function is also pure, in which case, pre-computing an output becomes a recursive operation. Note that actual recursion, where a function calls itself, is allowed and may be required in places... for example, with an implementation of a factorial function)
466463- There are code paths where uninitialized values can be read (this includes reading an **out** parameter prior to writing to it).
467464
468465There are probably other things that prevent a function from being pure.
469466
470467**pure** will generally only be used on **function**s; **procedure** is nevertheless valid because the output may be an **out** parameter, so long as the procedure's body follows all of the rules of a pure function.
471468
472469### Nuances
473470
474471- What happens if the pre-computation of an output value would cause an exception to be raised (e.g. division by zero)?
475472- What happens if the pre-computation would cause an infinite loop? How well can this be detected via finite state analysis rather than a timeout? (It's likely very difficult to do it purely via finite states - see [Turing's Halting Problem](https://en.wikipedia.org/wiki/Halting_problem)).
476473- What happens if a constant is declared to equal a pure function (e.g. "**const** QuarterPi = atan(1);" if atan is declared and proven pure). On the surface this seems perfectly valid, but what happens if optimizations are turned off?
477474
478475CuriousKit ([[User talk:CuriousKit|talk]]) 01:20, 17 June 2018 (CEST)
479476
480477## Support for Traits
481478
482479As a user who never got warm with the concept of interfaces, I'd like to suggest support for traits [2](https://en.wikipedia.org/wiki/Trait_(computer_programming)).
483480
484481## Support for Promises
485482
486483I know there are TThread.ExecuteInThread, Synchronize, Queue, etc. But JavaScript's promises [3](https://en.wikipedia.org/wiki/Futures_and_promises) are so intuitively to use that I'd love to see support in FPC. Could be an enormously handy feature when dealing with tasks for which, on the one hand, TThread would be overdimensioned, but on the other hand, doing the task in the main thread would on the other hand cause lags. I'm especially thinking about web requests, loading data from a file (which could be on a network drive), etc.
487484
488485# Other
489486
490487## Fixes branch releases
491488
492-Already done: <s>Currently we only have snapshots of the fixes branch, and it would be nice to also have them as releases. To have releases, those builds would have to be tested by someone, so I volunteer for that. What is needed is a testing checklist, and the start of it can be found on my page, User:Arny. Any further ideas are welcome!</s>
489+Already done: Currently we only have snapshots of the fixes branch, and it would be nice to also have them as releases. To have releases, those builds would have to be tested by someone, so I volunteer for that. What is needed is a testing checklist, and the start of it can be found on my page, User:Arny. Any further ideas are welcome!
493490
494491- This is already done and maintained for v0.9.28 onwards of Lazarus. Downloads of *fixes* releases are available on SourceForge.
495492
496493## See Also
497494
498495- [[Bounties]] - A way to make sure your feature idea is implemented.
499496- [[How do I create a bug report]] general information on submitting bugs, what should be covered in a bug report, and using the bug tracker.
500497- [[Tips on writing bug reports]] detailed information on what should be covered in a bug report.
501498- [[Database bug reporting]] Specific info and sample programs for database bugs
502499- [[Moderating the bug tracker]]
503500
504501---
505502*From the Free Pascal wiki, page "Feature Ideas", as it stood on 2022-12-20 after a change by Bart, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).*
506503Category: Lazarus
507504Category: Proposals

Back to history