[fpc-devel] TFieldDef.Size vs TField.Size

michael.vancanneyt at wisa.be michael.vancanneyt at wisa.be
Thu Feb 24 10:16:43 CET 2011



On Thu, 24 Feb 2011, Martin Schreiber wrote:

> On Thursday 24 February 2011 09:49:51 michael.vancanneyt at wisa.be wrote:
>>> Agreed. In MSEgui tmsestringfield.size is the maximum allowed character
>>> count for the field. 0 = no limit. tmsebufdataset stores string data as
>>> UnicodeString instead to use a fixed record layout.
>>
>> But here you implicitly assume that you have a fixed number of bytes per
>> character. You should always be explicit about such things, since this is a
>> non-trivial assumption.
>>
> I don't understand.

"tmsebufdataset stores string data as UnicodeString instead to use a fixed record layout."

If you say "fixed record layout", this means you assume that each character
uses the same amount of bytes, and that the size of the string is limited,
otherwise I fail to see how you can have fixed record layout.

Michael.



More information about the fpc-devel mailing list