Jump to content

All Activity

This stream auto-updates     

  1. Today
  2. jarto

    Checkbox Wordwrap

    Yes, both the combo and the radiobutton were changed. The previous ones were a lot more complicated as they used JS for all resizes while the new one uses pure CSS. The new ones are a lot faster and they don't run into problems in case you happen to hide a parent component while any of them are resizing. That's because once the component is not visible any more, ClientWidth, ClientHeight and ClientRect return 0 or even negative values. So if you have a TW3CheckListBox, which is constantly dynamically drawing and hiding lines, it'd be a pain to make it work with the previous versions.
  3. Daniel Eiszele

    Checkbox Wordwrap

    I seem to remember they were working in a previous version of SMS so something must have changed? I loaded an old project which I had to amend to get it to compile, so this suggests the combobox at least has changed?
  4. IgorSavkic

    Checkbox Wordwrap

    Sometimes these composite controls are good but in other not really, I had a lot of problem with TCheckBox in styling and flex positions so I've started using instead simple div as container and inside span for caption and editbox (check input) and all works exactly as I want. So perhaps checkbox control should be simplified.
  5. jarto

    Checkbox Wordwrap

    This is a bit more tough problem, than I anticipated. The current TW3CheckBox and TW3RadioButton are based on TW3Label, which does all the aligns and word wraps automatically through CSS. That makes them very fast and light as they don't need any resize code. However, once you add that check mark or radio toggle, it becomes way harder to properly do horizontal alignments and word wraps. I first thought that I just apply the css class to the wrong container (which I do), but that's not (only) the case. So I am able to fix this so that Word Wrap works, but can't get center and right alignments to work no matter what I try.
  6. lynkfs

    swipe

    just for reference : I'm using the SmartCL.Controller.Swipe controller to enable swiping I noticed that on Android phones I need to change the default parameters to something like constructor TW3SwipeController.Create(const AOwner:TW3TagObj); begin inherited Create(AOwner); FHRange:=TW3SwipeRange.Create(20,90); // [min]---X---[max] //20-40 FVRange:=TW3SwipeRange.Create(20,90); // [min]---Y---[max] //20-40 Latency := 55; //35 Options := []; //[coStrictTarget]; end; otherwise it wouldn't detect a swipe reliably I'll do some more testing on different touch-enabled hardware platforms (btw: the controller has properties to change these parameters in code)
  7. Yesterday
  8. jarto

    Checkbox Wordwrap

    That property doesn't seem to work. Let me have a quick look. Yep, confirmed. There are issues with other properties as well. On it...
  9. Daniel Eiszele

    Checkbox Wordwrap

    Can anyone confirm whether or not wordwrap is working for Checkbox components in the current Alpha (3.9.1.169)? Dropping a checkbox on the form, typing a really long caption and setting wordwrap to true in the property inspector doesnt seem to work.
  10. Last week
  11. jarto

    Database development

    First picture is from a manually constructed dataset. Second one is from sqlite-database. Doesn't look beautiful, but you can see data-aware versions of TW3Memo, TW3Label and TW3StringGrid. All connected to the same Data source.
  12. jarto

    ide browser sensing

    Login protected is the only safe way to go. If security is not that important in this project, I'd go with the url parameter.
  13. lynkfs

    ide browser sensing

    I'm working on a project which has 2 (inter)faces : one where the user is in a design phase, and one where the end-result is being displayed The idea is that there will be users in the role as designer, and other users which will be just using the end result. These other users should not even be aware of the design environment I'm looking for the best way to distinguish between these 2 states. In principle this could be solved by dividing the project into 2 separate projects letting the user switch between these environments at will (like selecting a menu item, maybe login protected) have a 'switch' parameter in the url (like /index.html?switch=design) I was looking at the option where the switch would be dependent on browser detection (ide browser or any other browser) Exploring options
  14. jarto

    opacity settings

    The Opacity-property should be a number between 0 and 100. The RTL changes that to the proper css value. You also need to set AlphaBlend to true. I'll fix the default value.
  15. jarto

    ide browser sensing

    Altering UserAgent is probably the best way to go as otherwise we want to keep the Internal Browser as close to a real browser as possible. @lynkfs may I ask why you need to detect this?
  16. lynkfs

    opacity settings

    opacity settings of TW3Panel (and probably of the other visual controls as well) are not rendered correctly The css opacity style is a float between 0 and 1, current designer expects an integer between 0 and 255
  17. lynkfs

    ide browser sensing

    or ping the socket server let's ask @jarto
  18. Daniel Eiszele

    ide browser sensing

    I imagine the smartmobilestudio team could alter the "UserAgent" Header sent with html requests to include some parse-able content that identifies it as the internal browser?
  19. lynkfs

    ide browser sensing

    I suppose we could check the browsers url object. If it is something like 'http://127.0.0.1:8090' it might be the internal ide browser Must be a better way
  20. Daniel Eiszele

    ide browser sensing

    I'm in the middle of a project where I'm asking myself the same question:)
  21. lynkfs

    ide browser sensing

    What would be the best code to see if a project runs in the IDE-browser or whether it runs natively in any other browser ?
  22. jarto

    Database development

    What I am now using for testing is to read the db-file to memory and accessing it there. After that, the db can be saved to a stream. However, when doing this infrastucture, it has to be versatile enough, so I don't restrict it only to a memory based sql database. It needs to be extendable so, that the sql-queries could just as well be sent to a remote server or a cloud based database.
  23. Earlier
  24. IgorSavkic

    Database development

    > Today I started then adding SQLite. I started by downloading a database file with TW3HttpRequest and loading it from a stream. Again, a few > bugs and improvements had to be made, but now it works and I have a nice mechanism for loading any binary data from a file. Is that for readonly sqlite databases? Or do you mean to store updated one in localstorage? > But now then... Making it possible to read the results of a SQLite query through a dataset.... Here I hit a little road block and don't know how to proceed. It's > simple to make a select-query and access that data for results, but what's the best way for me to know what the fields are? Their names and datatypes SQLite on desktop returns both fieldname and datatype, I guess that JS SQLite version doesn't return all that, so I think best is just to use Variant for all fields, and leave to user of Dataset to access it AsStr, AsInt, AsFloat... After all writer of that query should know what columns he'se selecting in query and what are datatypes.
  25. lynkfs

    Database development

    there is also the system.db.pas unit, which provides some db and sql based references
  26. jarto

    Database development

    Heh, well, this actually looks now a lot easier. Sqllite actually returns the parsed column names in the results. It even works with field aliases: lower(employees.FirstName) as Representative That was correctly returned as Representative
  27. jarto

    Database development

    Reading a bit of Lazarus source, it seems they don't have a full blown sql parser. For example, they don't allow updates if the select is from multiple tables or derived tables. So it's probably a good idea to aim at being able to show a dbgrid from a select-query and try to retrieve and parse the field names. I'd better add a possibility to provide or adjust field names as well. After all, if you use complicated SQL, you do know what your columns are and what you want to view.
  28. lynkfs

    Database development

    They must have some sort of an sql parser. Some links : Commercial vcl (delphi tokyo) parser : http://sqlparser.com/download.php http://sqlparser.com/dlaction.php?fid=gspdxe10_2_tokyo_trial&ftitle=General%20SQL%20Parser%20VCL%20for%20delphi%20XE10.2%20tokyo%20trial%20version and some really old ones https://torry.net/quicksearchd.php?String=sql+parser&Title=Yes http://www.felix-colibri.com/papers/db/sql_parser/sql_parser.html to write a complete sql parser from scratch might be a big job
  29. jarto

    Database development

    Seems like DBGrid in Lazarus can parse this properly as well: select lower(customers.FirstName) as FirstName,lower(customers.LastName) as LastName, lower(employees.FirstName) as Representative from customers,employees where customers.SupportRepId=employees.EmployeeId; The dataset used is chinook.db from here: https://www.sqlitetutorial.net/sqlite-sample-database/
  1. Load more activity
×