Recent Posts

Pages: 1 ... 5 6 7 8 9 [10]
91
Development / Re: Unreadable font when testing wx-master
« Last post by Miguel Gimenez on August 15, 2019, 07:38:46 pm »
The current nightlies don't understand v1. If you are working with 3.1.2 or newer version you will loose all your font settings when using the nightly, nothing too important. If you mix wxmaster and wx3.1.2 you will then get the micro font, but it also has a simple solution and 3.1.2 has been used only by some people from this forum.

I intend to report this to wx devs because there are more software using wxWidgets that can benefit from this correction.
92
Development / Re: Unreadable font when testing wx-master
« Last post by oBFusCATed on August 15, 2019, 07:23:02 pm »
I'm not sure there is long a term benefit to fix this. The only real issue we should care is moving from cb+wx3.1.2 to cb+wx<3.1.2 or what happens if we go back to a version which doesn't understand v1 font string?
93
Should have quoted your following sentence as well... but yes, i already told you two times what the problem is and how to fix it, i am done here.
94
Welcome to Linux where unlike in Windows the current directory is not on the search path.

Could you like stay away from this discussion, because you are not adding anything to it? If you like to insult people, do it elsewhere.
95
Embedded development / New arduino project SketchesDir does not exist
« Last post by piscvau on August 15, 2019, 02:42:56 pm »
Hello
I just installed Codeblocks version 17.12 and Arduino extension  from here https://github.com/provideyourown/CodeBlocks-Arduino
Plus template from https://github.com/obfuscated/cb_arduino_template

When  creating a new arduino project I get the following error message :
SquirrelFunction<> call failed
AN ERROR HAS OCCURED [the index 'SketchesDir' does not exist].
I am on Xubuntu Bionic.
I suspect it comes from my tree structure but checked it several times and do not succeed in solving the problem.

my arduino preferences indicate that sketchbooks are in :
/home/odile/Documents/dev_logiciels/arduino/SoftKnit21_testing_with_arduino/ (see confirmation in attachment)

.codeblocks tree structure is as follows :
── arduino -> /home/odile/Documents/dev_logiciels/arduino/arduino-1.8.9
├── default.conf
├── helpers
│   ├── end_leonardo_bootmode.py
│   ├── start_leonardo_bootmode.py
│   └── test_avr_size.py
├── share
│   └── codeblocks
│       └── templates
│           └── wizard
│               └── arduino
│                   ├── files
│                   │   ├── cores
│                   │   │   ├── CDC.cpp
│                   │   │   ├── HardwareSerial0.cpp
│                   │   │   ├── HardwareSerial1.cpp
│                   │   │   ├── HardwareSerial2.cpp
│                   │   │   ├── HardwareSerial3.cpp
│                   │   │   ├── HardwareSerial.cpp
│                   │   │   ├── HID.cpp
│                   │   │   ├── IPAddress.cpp
│                   │   │   ├── main.cpp
│                   │   │   ├── new.cpp
│                   │   │   ├── Print.cpp
│                   │   │   ├── Stream.cpp
│                   │   │   ├── Tone.cpp
│                   │   │   ├── USBCore.cpp
│                   │   │   ├── WInterrupts.c
│                   │   │   ├── wiring_analog.c
│                   │   │   ├── wiring.c
│                   │   │   ├── wiring_digital.c
│                   │   │   ├── wiring_pulse_asm.S
│                   │   │   ├── wiring_pulse.c
│                   │   │   ├── wiring_shift.c
│                   │   │   ├── WMath.cpp
│                   │   │   └── WString.cpp
│                   │   ├── libraries
│                   │   │   └── libraries.cpp
│                   │   └── sketch.cpp
│                   ├── logo.png
│                   ├── README.md
│                   ├── wizard.png
│                   ├── wizard.script
│                   └── wizard.xrc
└── sketches -> /home/odile/Documents/dev_logiciels/arduino/SoftKnit21_testing_with_arduino

I would widely appreciate any help.
piscvau

96
Welcome to Linux where unlike in Windows the current directory is not on the search path.

This is true for cmd.exe, but not for PowerShell. M$ is slowly approaching to Linux.
97
Development / Re: Unreadable font when testing wx-master
« Last post by Miguel Gimenez on August 15, 2019, 01:57:45 pm »
OK, the patch works. I will open a ticket in wx site.

The problem is:
  - wx3.1.1 uses v0 format for font-to-string conversion. It doesn't understand v1, so using a wx3.1.2 or newer C:B "corrupts" the font information in default.conf because they save it in v1 format, so wx3.1.1 reverts to a default font (MS Sans Script - Normal - Blank size).
  - wx3.1.2 saves in v1 format but read both. The problem is it saves a 0 point size, but it "corrects" this recalculating the size on load.
  - wx3.1.3 is like 3.1.2, but it uses the value read without checking, so fonts saved with wx3.1.2 will get a near zero size (the closest practical size).

Jumping directly from 3.1.1 to 3.1.3 does not have issues, because 3.1.3 will read the v0 format.

This is a problem normal users won't see because they stick to nightlies, but devs and others like me will find soon or later when changing back and forth between versions.
98
when you are in the directory you need to write ./wx-config, NOT wx-config

Welcome to Linux where unlike in Windows the current directory is not on the search path.

And now head on and fix autoconf...
99
And, then tell me what wx-config --prefix returns or I will add you to the list of people who is not able to be helped by me!

I was reading through similar threads (in wxwidgets forum) and in one thread someone told that when you are in the directory you need to write ./wx-config, NOT wx-config. Cool, now I know something you didn't know and revealed to me in the first place. So now, ./wx-config --prefix returns:

/Users/Krice/Documents/wxw

(I guess it's safe to tell my osx username, it's not like it's a mystery...)

And that's where wxwidgets is installed. wxWidgets is also working, the minimal example compiles and runs fine.
100
Development / Re: Unreadable font when testing wx-master
« Last post by Miguel Gimenez on August 15, 2019, 12:02:43 pm »
If I open the nightly I get MS Sans Serif - Normal - Blank size
Opening CB-head with wx-head I get Fira Code - Normal - Size 10
Both cases use the same default.conf and I get a micro font.

In both cases changing anything in the font fixes the issue.

The last four changes to src/mws/font.cpp were in fact related to font sizes, I will check.

EDIT: 3.1.1 saves fonts in V0 format, the rest in V1. The difference is a new parameter, next to the version, with the point size:

3.1.1: <![CDATA[0;-13;0;0;0;400;0;0;0;0;3;2;1;49;Fira Code]]>
3.1.2: <![CDATA[1;0;-13;0;0;0;400;0;0;0;0;3;2;1;49;Fira Code]]>
3.1.3: <![CDATA[1;9.75;-13;0;0;0;400;0;0;0;0;3;2;1;49;Fira Code]]>

The font saved by 3.1.2 has a 0 point size, while the 3.1.3 one has 9.75. This V1 string with 0 point size is what causes the problem.

The font size is read in line 670 of src/msw/font.cpp, but it is not validated; probably line 690 should be changed from

Code: [Select]
if ( setPointSizeFromHeight )
        pointSize = GetPointSizeFromLogFontHeight(l);

to

Code: [Select]
if ( (pointSize == 0.0) || setPointSizeFromHeight )
        pointSize = GetPointSizeFromLogFontHeight(l);

I will check if this fixes the issue
Pages: 1 ... 5 6 7 8 9 [10]