JEDI Visual Component Library (JVCL)

repository·master·Indexed 20 days ago

https://github.com/project-jedi/jvcl

A comprehensive library of over 600 visual and non-visual components for Delphi and C++Builder (version 6 and newer). Distributed under the Mozilla Public License (MPL), JVCL requires the JEDI Code Library (JCL) to function. The library includes specialized suites such as Unified Interbase (UIB) for high-performance access to Interbase, Firebird, and Yaffil databases, as well as the UIL Time Framework for scheduling and date/time management.

Tokens
32.3K
Snippets
57
Records
182
Agent score
71%

What's inside JVCL

  1. Overview of JConvert CLI tool

    master

    JConvert is a command-line utility designed to convert Delphi Form (.dfm) files between text and binary formats.

    It is optimized for version control systems (like CVS) by only creating new files if a conversion actually occurred. This prevents unnecessary file changes from being flagged in your VCS when a file is already in the target format.

  2. Overview of JEDI Visual Component Library (JVCL)

    master

    JVCL is a comprehensive library containing over 600 Delphi and C++Builder visual and non-visual components. It is designed to be used in both open-source and commercial projects under the Mozilla Public License (MPL).

    Key Details:

    • Compatibility: Supports Delphi/C++Builder 6 and all newer versions.
    • Dependencies: Requires the JCL (JEDI Code Library) to function.
    • Licensing: Distributed under the Mozilla Public License (MPL).
  3. Overview of the PackagesCheck developer tool

    master

    PackagesCheck is a developer tool designed to manage package dependencies. Its primary objectives are to identify and remove useless dependencies and to prevent missing dependencies within packages.

    It achieves this by combining a simple Pascal parser with an XML configuration file that stores information about the units provided for each target. The tool allows you to configure specific settings for each target, including:

    • Compiler symbols: Used for evaluating compiler conditions.
    • Include directories: Directories used to find included files.
    • Provided units: A list of units provided by specific packages.
  4. Overview of JvExVCL directory structure

    master

    JvExVCL is organized into two main directories:

    • . oot: Contains the preprocessed files ready for use, including the jpp.exe (JCL pascal preprocessor) and the preprocess.bat utility.
    • source\: Contains the raw source files that require preprocessing before they can be used. This includes the Delphi language preprocessor (dpp.exe), the base system interfaces (JvExControls.pas), and the extended VCL classes (JvExXxx).
  5. Overview of the JEDI Surveyor toolkit

    master

    JEDI Surveyor is a complete toolkit for creating, submitting, and evaluating surveys. It consists of three primary applications:

    1. JEDI Survey Builder (jsb.exe): Used to create surveys. Surveys are exported as single XML files.
    2. JEDI Surveyor (js.exe): Used by clients to reply to survey questions. Once completed, the response is submitted via e-mail to a configurable recipient.
    3. JEDI Survey Reporter (jsr.exe): Used to collect and analyze responses. It displays statistics and results and can export reports to formats such as XML and HTML.
  6. Use TJvValidateEdit for validated data entry

    master
    The TJvValidateEdit component (unit JvValidateEdit) is a specialized edit control that inherits from TJvCustomEdit. It is designed to control user input by restricting allowed characters and formatting the display based on a specific DisplayFormat. It supports various data types including currency, floating point, integers, and custom character sets.
  7. How JEDI Surveyor interfaces and implementations work

    master

    The toolkit is designed around a strict separation of interfaces and implementations.

    • Interfaces: All survey operations are controlled through interface instances defined in JvSurveyIntf.pas. The core interface is IJvSurvey.
    • Implementation: The default implementation is provided in JvSurveyImpl.pas (and JvSurveyUtils.pas), which uses XML files for storage.
    • Factory Pattern: To create an IJvSurvey instance, the application uses a function pointer named CreateSurvey defined in JvSurveyIntf.

    Developer Note: When building applications using this toolkit, you must include the JvSurveyImpl unit in your project. This ensures that the CreateSurvey function pointer is assigned a valid factory function at runtime. Because the interfaces use COM/OLE/Automation compatible data types, you can implement alternative storage backends (e.g., via SOAP or COM) without changing the application logic.

  8. Handle appointment data refresh in TJvTFScheduleManager

    master

    When the server needs to update appointment data from physical storage, it fires specific events. You must implement handlers for these events to retrieve data and update the appointment properties.

    • OnRefreshAppt: Fired when a specific appointment object in memory needs updating. The appointment's Modified property is set to False before the event fires.
    • OnRefreshSched: Fired when the server needs to refresh all appointments linked to a specific schedule (provided via the Sched parameter). The Modified property for each linked appointment is set to False before the event fires.

    If you need to manually mark an appointment as changed, call TJvTFAppt.SetModified.

    // Example: Handling OnRefreshAppt to reload data from disk
    procedure TMyManager.ScheduleManagerOnRefreshAppt(Appt: TJvTFAppt); 
    begin
      // Retrieve data from physical storage
      Appt.Description := LoadDescriptionFromDB(Appt.ID);
      // ... set other properties
    end;
  9. Custom drawing in TJvTFDaysPrinter

    master

    TJvTFDaysPrinter provides several events that allow you to perform manual drawing on the grid components.

    Important: Buffering and Canvas Usage All drawing in TJvTFDaysPrinter is buffered to eliminate flicker. Because of this buffering, you MUST use the canvas supplied by the aCanvas parameter provided in the event. Do NOT use the control's own canvas for custom drawing.

    Available drawing events include:

    • OnDrawAppt: Fires after the grid draws an appointment but before it is committed to the canvas. Use this to manually draw appointments.
    • OnDrawApptBar: Fires immediately after the appointment bar is drawn. Provides Appt (the appointment), Col (column index), BarRect (bounding rectangle), and TimeStampRect (rectangle representing actual start/length).
    • OnDrawColHdr: Fires after the column header is drawn.
    • OnDrawCorner: Fires after a grid corner is drawn.
    • OnDrawDataCell: Fires after a data cell is drawn.
    • OnDrawGroupHdr: Fires immediately after a group header is drawn.
    • OnDrawMajorRowHdr: Fires after the major row header is drawn (only if RowHdrType is rhFancy). Index is set to the last row of the hour.
    • OnDrawMinorRowHdr: Fires after the minor row header is drawn (only if RowHdrType is rhFancy).
    • OnDrawRowHdr: Fires after the row header is drawn (only if RowHdrType is rhGrid).
  10. Handle shared appointments with RepeatGrouped

    master

    The RepeatGrouped property on TJvTFGlanceViewer determines how shared appointments (appointments belonging to multiple schedules/resources) are displayed in the viewer.

    • If RepeatGrouped is True: Each resource sharing the appointment gets its own logical line. For example, if Appt1 is shared by Bob, Jen, and Mike, it will appear as 3 separate lines.
    • If RepeatGrouped is False: Shared appointments are aggregated into a single line. Appt1 would appear as one line representing Bob, Jen, and Mike.