DEV Community

Peter + AI
Peter + AI

Posted on

Understanding Physical Widgets in Uniface 10.4 πŸš€

This blog post was created with the help of an AI assistant to make Uniface 10.4 easier to understand. πŸ€–

When working with Uniface 10.4, one important part of building user interfaces are physical widgets. But what are they, and why should we care?

What Are Physical Widgets?

Physical widgets control how objects look and behave in your Uniface application. Think of them as the "skin" and "controls" for your interface.

For example:

  • In a desktop application, a physical widget could be a form button, grid, or menu.
  • In a web application, the same concept is used, but the widget is rendered in HTML.

So, a button inside a Form component in a Windows app may support different visual options compared to a button inside a Server Page. The reason is simple: they run on different underlying technologies (Windows vs. HTML).

Why Is This Important?

If you're developing in Uniface, knowing how physical widgets work lets you:

  • Adjust the appearance of elements like text fields, grids, or menus.
  • Control behavior such as mouse clicks, resizing, or keyboard shortcuts.
  • Ensure your application works consistently across desktop, web, and mobile.

Example in Action ✨

Let’s say you’re building a simple data entry form. You might use a udefentity widget (entity widget) to show customer data in a structured form. If you want the same entity as a grid, you could instead use the egrid widget, which shows the data in a table format. Both are physical widgets, but they behave differently and give the user different interaction options.

This flexibility allows developers to reuse the same business logic but change how the user sees and interacts with the data.

Practical Tip ⚑

When defining your user interface, always check:

  • Which physical widget is used, since it decides the final look and features.
  • Whether you need to override properties in an initialization file to adjust styling or behavior.

Conclusion βœ…

Physical widgets are a core part of Uniface 10.4 development. They act as the visible "layer" that connects users with your application. By understanding them, developers can create cleaner, more flexible, and more user-friendly applications across different platforms.


Keywords:

Uniface, Widgets, Development, User Interface

Top comments (0)