Search found 156 matches
- Thursday 1st December 2022 7:16pm
- Forum: General
- Topic: Exposing bytes for what they really are
- Replies: 4
- Views: 2091
Re: Exposing bytes for what they really are
Here is a demonstration of little endianess, and the answer to the above. Priceless. '============================================================================= Public Sub Main() DisplayMemoryOfInteger(&Babe&) DisplayMemoryOfInteger(&HBabe) End '=======================================...
- Thursday 1st December 2022 6:01pm
- Forum: General
- Topic: Exposing bytes for what they really are
- Replies: 4
- Views: 2091
Re: Exposing bytes for what they really are
Just for completeness, here are the printable* ASCII characters, arranged by their byte value codes. 0 1 2 3 4 5 6 7 8 9 A B C D E F 00100000 &20& 32 ! " # $ % & ' ( ) * + , - . / 00110000 &30& 48 0 1 2 3 4 5 6 7 8 9 : ; < = > ? 01000000 &40& 64 @ A B C D E F G H I J...
- Wednesday 30th November 2022 2:17pm
- Forum: General
- Topic: Exposing bytes for what they really are
- Replies: 4
- Views: 2091
Re: Exposing bytes for what they really are
You may have wondered why I wrapped my hex values in ampersands rather than use the traditional '&H' prefix. Consider the following Gambas code: Print Val("&Babe&"), &Babe& Print Val("&HBabe"), &HBabe Print Val("&HBabe&"), &HBabe&...
- Tuesday 29th November 2022 5:02pm
- Forum: General
- Topic: Exposing bytes for what they really are
- Replies: 4
- Views: 2091
Exposing bytes for what they really are
Bytes are the fundamental unit of storage in most modern computers. They are composed of eight bits, which can be considered two groupings of four. For convenience sake, binary numbers can be written in shorthand using hex numbers. Each grouping of four corresponds to a hex digit. The these two grou...
- Tuesday 29th November 2022 4:58pm
- Forum: General
- Topic: Spaces instead of Tabs in a text area, did I miss a better way?
- Replies: 4
- Views: 1599
Re: Spaces instead of Tabs in a text area, did I miss a better way?
Thanks. Indeed I have considered it, and intend to use it for viewing/editing source code files for which it is aware. I'm trying to stay lightweight and make the code transformable onto other platforms so I don't want to employ anything that is too Gambas specific for the core functionality. The Ta...
- Monday 28th November 2022 9:26pm
- Forum: General
- Topic: Spaces instead of Tabs in a text area, did I miss a better way?
- Replies: 4
- Views: 1599
Spaces instead of Tabs in a text area, did I miss a better way?
Quite a while ago I went off on tabs in source code documents. https://forum.gambas.one/viewtopic.php?p=1500 https://forum.gambas.one/viewtopic.php?p=1516 Mind you, they are a superb field delimiter to use for grid data, including on the clipboard. I am currently writing a masterpiece, well, at leas...
- Friday 25th November 2022 9:45pm
- Forum: General
- Topic: Resize a picture
- Replies: 5
- Views: 867
Re: Resize a picture
Does this "stretch" work for you? It seems to do what your shell command intends. (I just noticed PJBlack's second line, so here is an example.) Ced '============================================================================= Public Sub Main() Dim P As Image = Image.Load("~/Pictures...
- Wednesday 23rd November 2022 2:55pm
- Forum: General
- Topic: Allowable characters in sqlite3 database file names
- Replies: 4
- Views: 715
Re: Allowable characters in sqlite3 database file names
The naming conventions of databases have always been a pain. With sqlite and others, going forward, I am using split_with_underscore , all lower case names, no other special characters. But that is within the database. This is apparently a Gambas' specific problem. The OS (Ubuntu on Raspberry Pi) ha...
- Wednesday 23rd November 2022 4:17am
- Forum: General
- Topic: Allowable characters in sqlite3 database file names
- Replies: 4
- Views: 715
Allowable characters in sqlite3 database file names
I'm running into a bit of quirky behavior and am wondering if anybody else has experienced it or can confirm it. My program has an edit field to enter a database name, which in my rough draft I don't edit check, then the program either creates or loads the file depending upon whether the file exists...
- Saturday 13th August 2022 12:20am
- Forum: General
- Topic: format, cfloat, math operations
- Replies: 4
- Views: 1103
Re: format, cfloat, math operations
Your English is plenty fine. I was surprised "val" didn't work. So, when you can't find a function, roll your own. If you need to make it really fast (doubtful) you can put it in a shared library, but that is a different topic. In pure sweet code, this should work for you: Maybe somebody s...