Debugging
What FastGrid information will be logged to browser console.
0 - logs only fatal errors,
use for production releases,
1 - logs only errors,
2 - logs errors and warnings, must be set or higher for
DebugCheck,
3 - also logs informational messages,
4 - also logs times spent by individual actions, if exceeded
DebugMinTime or
DebugPaintMinTime,
5 - also measures the spent times by browser layout / reflow,
can slow down paint!
If checks the input JSON data for errors, if there are not set unknown attributes or tags.
Requires setting DebugLevel >=2.
0 - no checking, no warnings,
use for production releases,
1 - checks only unknown tags,
2 - checks also unknown attributes in tags
Cfg,
Format,
Font,
Place,
RowParts (also if defined separately),
ColParts (also if defined separately),
DefRows,
DefCols,
DefCells,
DefToolbars,
DefTools,
DefImages,
Cols (all columns defintions),
Toolbars (all toolbars and their cells),
Images.
Can slightly slow down loading!,
3 - checks also value types in attributes,
4 - checks also unknown attributes in all rows and cells (in
A),
can slow down loading if defined too many A attributes in rows!
5 - checks also value types in attributes in all rows and cells,
can slow down loading if defined too many A attributes in rows!
By default it is set to
5, but not for FastGrid default data. If modified FastGrid default data in sources, for testing purposes set DebugCheck=5 in
Defaults.js
It can be placed only to Cfg tag without any suffix _xxx!
Minimal spent time to be logged by
DebugLevel >=
4.
Minimal spent time to be logged by
DebugLevel >=
4 for actions during
Paint.
Grid method void
Debug
(int debuglevel = 3, any text = null, any text2 = null, ... )
Logs given
text and next parameters to browser console if
debuglevel <=
DebugLevel.
debuglevel also controls the color of the text,
0 - big red,
1 - red,
2 - orange,
3+ - light green.
debuglevel can be omitted and
text passed as the first parameter.
Every odd text is written in bold (text2, text4, ...).
FastGrid files
Complete FastGrid code is included in the only single file FGridE.js.
Only this file can be used in final distributed applications!
The other files are available only within some
FastGrid sources distribution:
Partial sources /
Backup sources /
Debug sources, and can be used only for development.
To use changes done in the other files in distribution, the files must be compiled to the
FGridE.js by provided compiler.
file
FGridE.js
Main FastGrid script.
It is the only required file to use FastGrid.
It must be included to the HTML page by <script> tag before using any FastGrid items.
If used
Content-Security-Policy, FastGrid requires at least these permissions:
default-src 'self'; script-src 'self' 'unsafe-eval'; style-src 'self' data: 'unsafe-inline'; font-src 'self' data:; img-src 'self' data:
file
FGridED.js
Loads
FGridE.js on demand.
Include the
FGridED.js instead of
FGridE.js to load the FastGrid main script
FGridE.js on demand only when some FastGrid is being created.
It must be in the same directory as the
FGridE.js.
It must be included to the HTML page by <script> tag before using any FastGrid items.
file
FGridEPart.js
Include the
FGridEPart.js instead of
FGridE.js to load the FastGrid main script using sources in
GridSrc directory.
It must be in the same directory as the
FGridE.js.
Use only for development.
It must be included to the HTML page by <script> tag before using any FastGrid items.
It must not be included in any web page available outside the licensed company.
It works only on IP addresses 127.0.0.1, 192.168.x.x, 10.x.x.x and localhost server name.
Available only with FastGrid sources.
file
FGridESrc.js
Include the
FGridESrc.js instead of
FGridE.js to load the FastGrid main script using sources in
JS and
GridSrc directories.
It must be in the same directory as the
FGridE.js.
Use only for development.
It must be included to the HTML page by <script> tag before using any FastGrid items.
It must not be included in any web page available outside the licensed company.
It works only on IP addresses 127.0.0.1, 192.168.x.x, 10.x.x.x and localhost server name.
Available only with FastGrid Debug sources.
file
Defaults.js
FastGrid source file with default settings.
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Texts.js
FastGrid source file with all texts and language dependent settings.
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Text_{Code}.js
FastGrid source file with specific language and all its texts and language dependent settings. The
{Code} is the language code like "DE" or "ES".
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Styles.js
FastGrid source file with all style settings like colors, borders, etc.
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Style_{Style id}.js
FastGrid source file with specific style and all its settings. The
{Style id} is the style name like "Black" or "White".
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Dialogs.js
FastGrid source file with all predefined menus.
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Toolbars.js
FastGrid source file with all default toolbars and default toolbar cells.
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Sheet.js
FastGrid source file with settings specific to display FastGrid as SpreadSheet.
It is loaded only if some input data is in
xlsx format or it defines
Book and
SheetJs attributes.
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Menu.js
FastGrid source file with implementation of menu dialog using FastGrid.
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
Calendar.js
FastGrid source file with implementation of calendar (datepicker) dialog using FastGrid.
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
UZIP.js
Third party script for ZIP compression, homepage at
https://github.com/photopea/UZIP.js, distributed under
MIT license.
Used to load and save
xlsx files.
It is the only third party code included in FastGrid!
Available only with FastGrid sources. It is compiled to
FGridE.js.
file
LucidaSansUnicode12s.woff2.js
FastGrid source file with special font used as FastGrid base font "LucidaSansUnicode".
This font is very fast to render and contains also special characters for FastGrid to speed up rendering and better character positioning.
This font does
not support
Light and
Condensed variants for
TextStyle &
4 and &
8.
Available only with FastGrid sources. It is compiled to
FGridE.js.
new 2.0 file
OpenSansUnicode12s.woff2.js
FastGrid
external font file with special font used as FastGrid base font "OpenSansUnicode". Located in
Grid/Fonts.
It is special external font file that can linked to html page optionally (after
FGridE.js) to use it as base font instead of "LucidaSansUnicode". When linked to page, it is used automatically.
This font contains special characters for FastGrid to speed up rendering and better character positioning.
This font supports
Light and
Condensed variants for
TextStyle &
4 and &
8.
new 2.0 file
OpenSansUnicode12sRegularBold.woff2.js
FastGrid
external font file with special font used as FastGrid base font "OpenSansUnicode". Located in
Grid/Fonts.
This is smaller variant of
OpenSansUnicode12s.woff2.js that does
not support
Light and
Condensed variants for
TextStyle &
4 and &
8.
new 2.0 file
OpenSansUnicode12sRegularSemiBold.woff2.js
FastGrid
external font file with special font used as FastGrid base font "OpenSansUnicode". Located in
Grid/Fonts.
This is smaller variant of
OpenSansUnicode12s.woff2.js that does
not support
Light and
Condensed variants for
TextStyle &
4 and &
8.
This font uses Semi-Bold version instead of Bold font.