HTML parser in Sciter v.3 supports attribute shortcuts allowing to write HTML in more compact form. Compare these two declarations that are identical (to the Sciter): Compact: <input|currency(itemPrice) value=1000> and standard: <input type=”currency” name=”itemPrice” value=1000> As you see the first one is slightly shorter and better readable (subjective of course). Here is full list of…
Category: HTML and CSS
CSS box-shadow support
Sciter version 2.0.2.3 contains support of shadows in CSS, see the ‘box-shadow’ property specification.
Q.tis – micro port of jQuery for Sciter.
I’ve published today Sciter 2.0.2.2 with q.tis – micro-port of essential jQuery features. Here is the list of supported functions. It is just enough to put include “t.tis”; in your code and any existing DOM function that returns array of elements will “automagically” produce the q-collection. In my implementation I am using the fact that…
Making TIScript syntax compatible with CSS.
Time to time when I need to define some CSS constructs in script I feel myself non-comfortable – CSS and JavaScript/TIScript use different syntax’es. Consider this code in JavaScript: function switchState() { element.style.backgroundColor = “rgb(126,0,0)”; element.style.transform = “rotate(45deg) translate(10px,10px)”; } Not so aesthetically pleasing. And not so effective as string parsing is involved. And yet…
W3C: “Selectors API Level 1” is out but …
"Selectors API Level 1" document started in 2006 has reached status of W3C Recommendation these days. Which means we may see it implemented uniformly across all browsers ( those browsers that are alive yet 😉 ). But I am disappointed by features provided by this API. It de-facto contains 6 methods but only two…
Use of CSS constants in script.
In Sciter you can define CSS constants using @const declarations like this: <style> @const TEST_STR:”test”; @const TEST_COLOR: rgb(128,0,0); @const TEST_NUMBER: 128; </style> and use them not only in CSS ( as @TEST_COLOR for example ) but also in script using accessor like this: var test_str = self.style.constant(“TEST_STR”); If you think that self.style.constant is too narrative…
Better CSS sprites
First of all I shall admit that current way of doing CSS sprites appears as a hack. OK, what exactly is the CSS sprite? (actually sprite is a wrong name for the entity but seems like it is already wide spread, sigh ) Sprite (here) is just a fragment (slice, portion) of some base image….
Sciter UI, application architecture
Architecture of applications that use Sciter based UI can be visualized as this: Typically such applications contain two distinct layers: UI layer that uses Sciter window with loaded HTML/CSS and scripts (code behind UI); Application logic layer, most of the time that is native code implementing logic of the application. Ideally these two layers shall…
Caret positions in HTML
Working on behavior:richtext again. This time for Sciter2. The behavior:richtext is the thing behind Sciter’s <richtext> element or <div contenteditable> in Web browsers. behavior:richtext in Sciter1 uses “flat” DOM model: div:element, paragraph:element, that model is similar to the RichTextBox in Windows. But in Sciter2 new behavior:richtext uses standard DOM model of HTML content: element:node, text:node,…
Sciter 2.0.0.12
Just published Sciter 2.0.0.12 SDK that is available at terrainformatica.com/sciter/sciter2-tech-preview.zip. What’s new in the build: Demos: bin/layered.exe (sdk/demos/layered) demonstrates use of WS_EX_LAYERED windows. That is about windows of non-rectangular shapes. W7 has better support of such windows so even animations are feasible on such windows. Just run the demo to see. CSS features: New layout…