From the blog

Customize your memory use with Unity 2021 LTS

In summer 2020, Unity provided support for Moon Studios when they were working to port Ori and the Will of the Wisp to Nintendo Switch. You can learn more about how we worked together to scale the project for this target platform in this case study. Moon Studios and Unity Accelerate Solutions (formerly Unity Professional Services) analyzed sections of code together, finding ways to tweak the particle systems and reduce memory usage. “When you’re targeting 60 fps on Nintendo Switch, you have to make sure every single aspect is optimized, including simulation, streaming, rendering, and graphics,” says studio founder Gennadiy Korol. Ori and the Will of the Wisps pushes the Nintendo Switch very hard in terms of memory use. The Accelerate Solutions team helped Moon make sure they were getting the best from these layers, focusing on native memory allocation.  Working with the team from Moon Studios, the Unity team measured the number of allocations from the different allocators. They also looked at the amount of memory allocated from each, which showed that the game was filling up some of the bucket allocators before even reaching the start of gameplay.   Increasing the size of the bucket allocator allowed extra room for small allocations that happen when playing the game. Allocating these small blocks from the bucket allocator gives the game a performance boost, helping it to hit the 60 fps target. The small allocations no longer come from the dynamic heap allocator, so this allocator contains just large blocks of memory. The allocator is less fragmented, which keeps the game running smoothly for longer.   Following the collaboration with Moon, the Accelerate Solutions team worked with the Optimization team, who developed the memory allocator customization feature that is now available in 2021 LTS.

Read More

Embarcadero InterBase 2020 Update 3 Released!

I’m delighted to announce that today Embarcadero has released a new version of its InterBase flagship database engine, InterBase 2020 Update 3. With this release, the company continues to improve the product’s quality and usability. UX Enhancements The most visible improvements are the user interface enhancements in the InterBase Manager utility for the Windows platform. In this release the InterBase Manager offers high-DPI support, and additional information like the version number and the current port in use, in an improved overall layout. As part of the UX improvement we have changed the fonts, colors, and overall look and feel, making these forms more modern. Noticeably, InterBase Manager now uses the PerMonitor V2 Windows UI model, and that has been migrated to and compiled with the latest version of Delphi.           The InterBase Manager window in InterBase 2020 Update 3 (on the right) compared to previous versions (on the left) In addition, the InterBase Server and Guardian property sheets have an improved UI (for example, the interface includes the entire path of the referenced folders rather than a trimmed version) and they are also made available when the database runs as a Windows Service.                           General Improvements Besides the UX enhancements, InterBase 2020 release 3 includes some additional features:  Expression Index can now be used to optimize query filters using STARTING WITH and LIKE predicates matching input expressions In IBConsole, the Object window and WISQL window now execute SELECT statements in precommitted reads mode, so they don’t stick to the transaction in the database. With this change, normal GC and sweep of obsolete versions will not be held back. InterBase 2020 Update 3 is also certified for use on more recent versions of the Windows operating system, Windows 11 and Windows Server 2022. Quality Work The release also addresses customer support cases and internally found quality issues, listed in the Doc Wiki product documentation. ADO.NET Support for Change Views As part of the improvements to InterBase, the team has also added Change Views support to the ADO.NET driver. For more information on ADO.NET and Change Views, refer to the ADO.NET documentation, or read the announcement blog post at https://blogs.embarcadero.com/interbase-ado-net-driver-update-enhances-visual-studio-support/.  The new ADO.NET driver is available on GitHub and NuGet, as it is not part of the regular product installation. More Information You can find more information on InterBase and the 2020 Update 3 at the following links: If you are an existing customer, the new version of the product is available on https://my.embarcadero.com, otherwise you can download the trial version at https://www.embarcadero.com/products/interbase/developer/free-download 

Read More

Extend TMS WEB Core with JS Libraries with Andrew: FontAwesome

This time out, we are exploring FontAwesome, another wildly popular JS library. Like Bootstrap last week, FontAwesome requires no JavaScript coding knowledge and very little in the way of HTML or CSS knowledge either.  And while it does have a lot to do with fonts, and is indeed truly awesome, the main benefit we’re going to get from FontAwesome in terms of our TMS WEB Core projects is its enormous icon library. Great. More Icons. Last week, we touched briefly on the topic of Bootstrap Icons. 1,600 or so freely usable icons that you can directly use in your projects. There are also Google Material Icons. Several thousand more icons that also come in five different styles. The Google Material Icons library is even included in the JavaScript Library Manager in the Delphi IDE, so getting started is easy enough. If you’ve used one of these sets of icons previously in your projects, you might be reluctant to switch to something else.  The look of the Google icons will be familiar to many and might be somewhat of a safe choice.  Long-time developers might feel a bit of a chill when reflecting back on icons of ages past. There was a time when you could pretty accurately guess what tools were used to create an app based entirely on how audacious the icons were.  Like acid-wash jeans and tie-dye shirts, these are thankfully well behind us and we now have mostly sane choices to pick from.  Also long gone are less-than-fun topics like multi-res bitmaps, bmp-vs-ico, transparency issues, and anything to do with scaling.  I suspect our children will never care what a pixel is because they won’t actually be able to see any individual pixels anywhere without a microscope.  Back to the topic at hand.  Like Google Material Icons, FontAwesome has a handful of different styles to choose from.  And I personally much prefer FontAwesome styles to the Google equivalents, but there’s more to the story than just the look of the icons.  Much more. Making Your Project FontAwesome The FontAwesome library was recently added to the “Manage JavaScript Libraries” list, sometime around TMS WEB Core 1.9.8 or so.  It lists both FontAwesome 4 and FontAwesome 5. FontAwesome 6 also came out a couple of months ago.  We’ll run into some of the differences closer to the end of this article.  But I think everything we’re going to cover today will work the same in any version unless otherwise noted.  One thing that is different between versions is the icons themselves – new icons are added and occasionally icons are changed or removed or, more likely, renamed or redesigned.  This can even happen mid-version, so something to keep an eye out for, particularly if you want to use the very latest icons.  If your project doesn’t already use FontAwesome, just pick the highest version available from the “Manage JavaScript Libraries” list and you’re done! If you’d like to use a  particular version of the FontAwesome library, or a particular CDN, or even host the libraries yourself, then the usual approach of adding files to your Project.html file works just fine as well.  Or you can use the JavaScript Library Manager to update the list to suit your particular needs.  Both FontAwesome themselves as well as any reputable CDN will […]

Read More

Managing displays with the Multi-Screen Window Placement API

With the release of Google Chrome 100 came the new Multi-Screen Window Placement API. This API allows you to enumerate the displays connected to your machine and to place windows on specific screens. We’ve wrapped this API with TMS WEB Core, so that you can use this inside your Web Applications with minimal effort.  Before we had this API, we could use the window.open() to control windows. This method however, is unaware of additional screens. We can specify the position by passing the coordinates as left and top and pass the size as width and height. To get the information about the current screen we could check the window.screen property.  How to use First of all we have to check if the API is supported. we can simply do this by calling the GetScreenAvailability function. this will return true if it is supported.  To get all necessary screen information you can call the following asynchronous function: GetScreensInfo. This will result in a TJSScreenInfo object containing a list of all the available displays as well as the current screen the window is rendered on.  screens := await(TJSScreeninfo, GetScreensInfo); screens.OnCurrentScreenChange := DoCurrentScreensChange; screens.OnScreensChange := DoScreensChanged; The Screens object also has 2 events: OnCurrentScreenChange: This event updates the screens object when the web application changes screen. OnScreenChange: This event updates the screens object when the browser detects that the displays have been changed.(i.e. adding/removing a display) The Screens object looks like this on my machine. As you can see I have to 2 Displays connected to my machine. And my CurrentScreen is “External Display 2” which is not my primary screen. Using the left and top properties of the TJSScreenDetails object, we can accurately position our window wherever we want on the display that you want. Before we can use the Multi-Screen Window Placement API we must ask the user for permission to use it. To do this, we can call the GetPermissions function. Be aware that this function is asynchronous. so you’ll have to await it. you can use it like this: allowed := await(boolean, GetPermissions); Weather around the world! Using this API we made a demo application that let’s you check the weather in several locations all around the world. If you have a multi display setup the weather popups will be shown on the screen the web application is not currently on.  The result will be something like this when clicking the button. Screen 1: Screen 2: And a screenshot from both screens together: To make this possible, we simply calculate how large the windows can be if we want to show a 5 x 2 table of windows. w := Math.floor((screens.screens[i].availableWidth – FColumns * 1) / FColumns); h := Math.floor((screens.screens[i].availableHeight – FRows * 51) / FRows); After that we loop over the columns and rows and calculate for each window the X and Y offset. we than add it to a WindowFeatures string and call the CreatePopup function.  for j := 0 to FColumns -1 do begin for k := 0 to FRows -1 do begin x := j * w + screens.screens[i].availableLeft + j * 1; y := k * h + screens.screens[i].availableTop + k * 51; Features := ” + ‘screenX=’ + IntToStr(x)+ ‘,’ + ‘screenY=’ + IntToStr(y)+ ‘,’ + ‘width=’ + IntToStr(w)+ ‘,’ + ‘height=’ + IntToStr(h)+ ‘,’ […]

Read More

How To Build Python Applications For Android Using DelphiFMX

This video is a continuation of the development of applications in Python using the Delphi GUI frameworks. Delphi and Python are two powerful programming languages that are not just ideal for windows application development but also for other platforms. Previously, Jim McKeeth introduced us to Delphi VCL for Python Module which gives developers the ability to take the powerful and mature GUI frameworks of Delphi’s VCL and use them in a Python coding environment. This time, the webinar will focus on another module, the DelphiFMX4Python which supports building Python applications for Android using the FireMonkey GUI library. How to build an Android App in Python using the Delphi FMX library module This webinar almost shares the same agenda as the first video where we build a functioning application in Python using Delphi’s powerful GUI library. However, instead of Windows-native VCL, this session will focus on Delphi’s cross-platform Firemonkey framework using the Delphi FMX module. Firemonkey takes advantage of GPU libraries to provide a hardware-accelerated, rich, user interface that is fast and looks great across multiple platforms. This library is compatible with Windows, macOS, Android, iOS, and Linux. The main course of this webinar will focus primarily on Android where Jim Mckeeth will demonstrate the process from installation to Android deployment. Aside from basic samples, the video will also show how you can take your Android app further by combining the strengths of Delphi and Python. The webinar will demonstrate how surprisingly easy to customize the Android app using the pre-built android application where all the source code is already available. It will also tackle how the Python4Delphi library can serve as a bidirectional bridge that allows you to develop parts of your app in Delphi and other parts in Python, merging both languages into a single cohesive solution. To learn more about DelphiFMX for Python, feel free to watch the video below. 

Read More

Rider 2022.1 Comes With Full Unreal Engine Support and Remote Development

.NET Tools News Releases Hello everyone, Our first release of the year, Rider 2022.1 is now available. You can download it from the JetBrains website, install it via the Toolbox App, or use this snap package from the SnapCraft store (if you are using a compatible Linux distro). We initially dubbed Rider 2022.1 a quality release with a focus on fine-tuning features and fixing bugs, but there are also some new features in the release build. Let’s check it out! Game development with Unreal Engine and Unity Rider is already widely used in the Unity development world, and it now comes deeply integrated with Unreal Engine support. This converts Rider into a full-fledged IDE for game development, no matter your game engine of choice. Unreal Engine support is available on all three major platforms: Windows, Linux, and macOS. It works natively with the .uproject model, saving you time on intermediate project model generation, supports Unreal Engine reflection mechanism, and integrates with Blueprints. You can learn more about Unreal Engine support in Rider in this blog post. As always, there are some new features and performance improvements for Unity development. Among the most notable ones is that Rider now supports .asmref Assembly Definition Reference files, as well as .asmdef files. We also improved load times for very large Unity projects, especially with slower disks or file systems. We’re also announcing RiderFlow – a new scenery tool for Unity. This is a free plugin for the Unity editor that is designed to help level designers, artists, coders, and the rest of the creative team easily create and manage scenes. When combined with Rider, they will provide you with a full suite of powerful tools to boost your Unity development at all stages. Remote Development (Beta) Rider now supports a Beta version of the long-awaited remote development workflow. It allows you to connect to a remote machine running Rider’s backend from anywhere in the world. All the processing happens on that powerful remote machine, and you can work on your project as seamlessly as if it were on your local machine. This functionality can be initiated from Rider’s Welcome screen or from a new application called JetBrains Gateway, which is available in the Toolbox App. What’s more, you can create, prebuild, share, reproduce, hibernate, and manage dev environments with JetBrains Space – a unified platform for the entire software development pipeline. Check out this blog post for more details. Other highlights You can now customize the new toolbar by adding new elements to both the left and right sides of the toolbar, as well as rearrange and remove widgets. Profiling with dotTrace is also available right from the Run/Debug widget’s More menu (the “kebab” icon). Fast mode has come to Docker and Docker-Compose solutions, which should significantly reduce build times during development. We’ve added full-text search in Search Everywhere. The new Text tab will show all text occurrences in the solution that match the string while you are typing it. We continue to improve support for C# 10, particularly global usings. We’ve implemented two new refactorings that are also available as context actions: Extract Global Using to introduce the concept of global usings in your project and Inline Global Using to refactor a global using into a regular using. We’ve added support for […]

Read More

How to choose the right static site generator

Most websites today fall into two categories – dynamic sites and static sites. Dynamic sites are interactive, and the user experience can be tailored to the visitor. These are the ones that might remember who you are across visits or deliver content that’s most applicable to the region you’re visiting from. They rely on a content management system (CMS) or database for rendering and can continue to grow in complexity as the organization’s needs grow. Static sites, however, generally display the same content to all users. They use server-side rendering to serve HTML, CSS, and Javascript files. While CMS backends have made dynamic sites easier to launch and maintain, static sites continue to grow in popularity. Static sites’ advantages include speed, security, and SEO. They’re also easy to maintain and highly scalable. Because the static site generators (SSG) store an already-compiled page on a CDN, they load a lot faster. All static site generators can be exciting and fun, but some require time and effort on configurations, detailed templating, or management tweaks. My team and I joke that I am one of the top blog-less SSG experts, so in this blog post, I’ll walk you through a toolkit for evaluating your project and then share some SSGs that deploy to GitLab Pages. Here are the SSGs I’ll review in this post: Hugo is written in Go with support for multi-language sites and complex content strategy. Zola is written in Rust with a single binary, no dependencies, and flexible features like Sass compilation. Jekyll is written in Ruby, built for blogging, and has a large collection of plugins and themes. Hexo is Node.js based with support for multiple templating engines, integrations with NPM packages, and one command deployment. GatsbyJS is React-based, works with any CMS, API, or database, and can be used for building headless experiences. Astro is Javascript-based, supports multiple frameworks, and is known for on-demand rendering via partial hydration. With so many static site generators available, selecting one for your project can be overwhelming. When evaluating which SSG is right for you, here are a few things to consider about your project, use case, and the type of work you’re looking to put into the site. Identify the use case It’s important to understand your site’s needs, purpose, and content. Are you building a personal blog, a landing page for a product, or documentation for a tech project? Consider whether you need a streamlined editor experience, content, and interactions with your user. The better you can identify the experience you’d like your visitors to have, the easier it will be to pick the feature set that can best support it. Specify languages and frameworks There are so many static site generators out there that you can find one in nearly every language and framework. Consider whether you want to learn a new language or use something you’re familiar with. Depending on how much time you’d like to invest in setting up, you should also review the installation details and see if you’re familiar with the templating language, dependencies, and theming layer. Review the Ecosystem Many static site generators will have starter repositories or sample sites where you can play around with functionality and components before diving into your project. When reviewing the ecosystem, think about the limitations of the […]

Read More

How to Supercharge Your Windows App Development Productivity

Whether you are working on a small software or a huge windows app development project, the process can be tedious, and it will surely consume lots of your time. Interestingly, there are many possible ways developers can do to boost their productivity. In this video, Jim McKeeth will share every possible tip and trick to supercharge your development productivity. With the help of some Embarcadero MVPs, Jim managed to compile the ultimate guide to effectively boost your productivity in developing software. The tips and tricks to supercharge your productivity One of the core tips shared by McKeeth in this webinar is to use Delphi above any other programming languages. Delphi is designed to provide an easy-to-use and easy-to-learn development environment allowing you to get things done quicker. He also encouraged developers to practice those simple yet often overlooked coding techniques to complete their work relatively faster. These include those keyboard shortcuts and other surprisingly effective tips from Alister Christie (Code Faster in Delphi). He also encouraged developers to utilize the use of component libraries because it is far more productive, safer, and faster to use those thoroughly rested libraries than using their own code. David Cornelius also suggested establishing an Environment consistency when coding while Bruce McGee encouraged automating builds using MSBuild. Embarcadero MVPs like Ian Barker encouraged the use of the so-called Pomodoro Technique to help you focus your efforts on timed chunks of work. Dalija Prasnikar, on the other hand, came up with her own list suggesting that a developer should learn how to reduce distractions and focus on work they know they can do at a given moment. Aside from the aforementioned techniques, the webinar will also share notable software and frameworks that you can use to supercharge your development productivity. These include the use of PyScripter, UltraEdit, and frameworks like Router4D, Safety4D, Bind4D, Simple ORM, Typora, IDE Visualizers, and Delphi Parser, Invoke, Everything (fast engine to search over your drives), HTTPie, and more. Feel free to watch the webinar below to learn more.   

Read More

How to deploy Shopify themes with GitLab

1.75 million sellers are using Shopify’s eCommerce platform, and every one of these online stores has a codebase that lives somewhere. You may have encountered some challenges while scaling your development efforts at your organization while working within Shopify. Setting up a process for repeatable deployments with GitLab can keep everything streamlined and safe. No one wants something going live in production before it’s ready. Here’s a simple development flow you are going to be able to replicate using GitLab CI/CD pipelines for Shopify theme deployments. Develop locally on a feature branch until you are happy with your local changes Merge your feature branch into your main branch → This will update the staging theme in Shopify When everything is ready to go live, create a new tag and push it to GitLab → The live theme will be updated automatically 🎉 This tutorial assumes you have set up a repository in a GitLab project. 1. Add your variables For security purposes, you don’t want to store your credentials for your Shopify site in your configuration file. You can use variables in GitLab to handle that. Use the ThemeKit CLI to retrieve all the available theme IDs from your Shopify store by entering this into your command line: theme get –list -p=[shopify-api-access-token] -s=[your-store.myshopify.com] Help: Generate API credentials in Shopify Open your project in GitLab, navigate to /settings/ci_cd, and open the variables section. Add four unique variables with their corresponding keys and values Key Value STAGING_THEME_ID [staging-theme-id-number] PRODUCTION_THEME_ID [production-theme-id-number] SHOP_WEB_ADDRESS [your-store.myshopify.com] SHOPIFY_API_ACCESS_TOKEN [shopify-api-access-token] Note: A protected variable will not show in the CI logs, which adds an extra layer of security. If you choose to protect your variables, you need to make sure that your main branch and the tag v* wildcard are protected as well. 2. Add a config.yml to your project repository This file may already exist, but config.yml needs to have the following to properly map the variables from step 1 with your Shopify theme for deployments. staging: password: ${SHOPIFY_API_ACCESS_TOKEN} theme_id: ${STAGING_THEME_ID} store: ${SHOP_WEB_ADDRESS} production: password: ${SHOPIFY_API_ACCESS_TOKEN} theme_id: ${PRODUCTION_THEME_ID} store: ${SHOP_WEB_ADDRESS} 3. Add a .gitlab-ci.yml file to your project Now set up your pipeline to run on specific triggers. Go to your local theme folder, create a .gitlab-ci.yml file at the project root, and add the snippet below. This snippet is the configuration for the CI pipeline. image: python:2 stages: – staging – production staging: image: python:2 stage: staging script: – curl -s https://shopify.github.io/themekit/scripts/install.py | python – theme deploy -e=staging only: variables: – $CI_DEFAULT_BRANCH == $CI_COMMIT_BRANCH production: image: python:2 stage: production script: – curl -s https://shopify.github.io/themekit/scripts/install.py | python – theme deploy -e=production –allow-live only: – tags It has two stages: staging and production. Each will install the ThemeKit CLI first and then deploy the repository to the corresponding theme. 4. Now push some changes to deploy Any code pushed to the main branch will set up a deployment to the staging theme in Shopify git commit -am “commit message” git push When you are ready to push changes to production, add a tag and push it. git tag -a “v1.0.0” -m “First release to production from GitLab” git push –tags Alternative option: Create a tag from GitLab That’s it! You’re now using CI to automate deployments from GitLab to your Shopify themes. Further refine this workflow by incorporating […]

Read More

5 Examples Of A Successful JS Grid

JavaScript is everywhere. It is used on millions of websites and isn’t going away anytime soon. This language is no longer restricted to your web browser as it’s also appropriate for server-side apps. When it comes to showing data, the Grid is one of the most fundamental and helpful JavaScript components. It is a common yet essential technology used by developers to display enormous data sets and, more significantly, to allow users to browse, sort, and interact with them. JavaScript Grids are a tool that allows developers to modernize and speed corporate processes by making it easier for their users to work with data. JS Grid enables us to present vast amounts of data without stuttering or freezing. They also help us save a lot of time when it comes to data management. This article will discuss 5 examples of successful JS Grid so that you can understand this tool better. Why are Data Grids Important?   Data grids are required in online applications that display a large amount of data, such as live reports, tracking statistics, etc. The following are some of the reasons why you should use a data grid in your next project: Data grids boost your application’s performance. Because most open source data grid libraries are small and light, they don’t have a lot of overhead. Virtual scrolling is also available in most libraries, improving user experience while scrolling through enormous amounts of material. Filtering, sorting, and pagination are characteristics of data grids that make it easier to navigate enormous databases. What is the Importance of Sencha Ext JS? Sencha Ext JS is a JavaScript framework that is used for creating data-intensive, cross-platform online and mobile applications for all modern devices. This JS framework comes with over 140 high-performance UI components that have been pre-integrated and tested. Ext JS is the most comprehensive collection of high-performance, customizable UI widgets in the industry, including HTML5 grids, lists, menus, panels, toolbars, trees, forms, windows, and more. As previously stated, the focus of this article will be on JS grids. Why is Ext JS Grid the Best in the Market? The Ext JS grid is an extremely useful component with its comprehensive functionality and many extensions. It simplifies app design since it does not rely on third-party libraries. Built-in Ext JS UI components like dropdown menus, grouping data, and other fascinating add-on functionalities also assist with data organization. In Ext JS, the grid uses buffered grid rendering. Users can use this option to browse thousands of data points without incurring the performance penalties of bringing them all into the DOM at once. Column locking is another handy feature of Ext JS. You can enable automatic locking by setting the column’s ‘locked’ settings to ‘true’ or by setting ‘enable locking’ to ‘true.’ Furthermore, programmers can embed components inside grid cells in Ext JS using the WidgetColumn class. For adding a Widget Column to your page, you simply have to set the xtype of the column to “widgetcolumn.” Ext has several helpful plugins. For instance, the Row Expander plugin adds an “expander” column to each row, allowing the user to reveal or hide the body of the row. Because users can minimize, increase, or hide columns based on their needs, this feature is critical. Another advantage of this feature is that […]

Read More