Comments (10)
What browser are you using?
from pencilcode.
I was using Mozilla Firefox when that thing came.But it works perfect in chrome n other
from pencilcode.
I noticed the same problem - Chrome 42 / Ubuntu 14.04
from pencilcode.
Do you notice if the text changes font before drawing incorrectly? I
suspect a font loading problem (where the font is measured before it is
loaded, then drawn after it loads).
On Mon, Jun 8, 2015 at 11:11 AM, Saksham Aggarwal [email protected]
wrote:
I noticed the same problem - Chrome 42 / Ubuntu 14.04
—
Reply to this email directly or view it on GitHub
#129 (comment)
.
from pencilcode.
https://github.com/dabbler0/droplet/blob/master/src/draw.coffee#L412 loads the font asynchronously, right?
from pencilcode.
@davidbau I was able to repro the situation you described by using a slow Internet connection from China. It goes like this:
Pencilcode loads in the browser default font (e.g. Times New Roman), then the real font loads, but bounding boxes in Droplet never updates, causing the problem described in the issue.
Do you think using something like https://github.com/smnh/FontLoader could work, making droplet render after the font loads?
from pencilcode.
We do use FontLoader in pencilcode - a modified version that fixed some
problems I had when testing it:
https://github.com/PencilCode/pencilcode/blob/master/content/src/FontLoader.js
There are two possible problems: either our FontLoader isn't working, or
it's working but not be forcing the redraw of the palette correctly. I
think I saw it once, but the main editor in Droplet redrew while the
palette didn't. Is that what you're seeing? If you've got a reliable
repro, any chance you might be able to debug it Frank?
On Tue, Jun 9, 2015 at 1:17 AM, Weihang Fan [email protected]
wrote:
@davidbau https://github.com/davidbau I was able to repro the situation
you described by using a slow Internet connection from China. It goes like
this:
Pencilcode loads in the browser default font (e.g. Times New Roman), then
the real font loads, but bounding boxes in Droplet never updates, causing
the problem described in the issue.Do you think using something like https://github.com/smnh/FontLoader
could work, making droplet render after the font loads?—
Reply to this email directly or view it on GitHub
#129 (comment)
.
from pencilcode.
@sakagg Does it still fail for you in the latest version of Chrome? To me it seems like a Firefox-only problem(Edge and Chrome both work fine for me).
from pencilcode.
After doing some logging, it seems like editor.redrawMain() was called properly after the fonts are loaded, but Droplet did not update itself correctly. I had to manually drag stuff around for them to update. Could it be because Firefox does some lazy rendering thing?
@dabbler0, do you have an idea as to what's going on?
@davidbau That's not what I'm seeing. The main editor did not redraw.
from pencilcode.
Chrome is rendering it better now, but not completely correct yet.
from pencilcode.
Related Issues (20)
- Not working properly in mobile HOT 1
- Email button not working HOT 3
- p5.js not working? HOT 1
- Don't return placeholder HTML for non-existing .js files
- Feature Request: API for "create new file with starter code"
- UX: Blocks mode activates keyboard too often on mobile device
- Pencil Code Embed: setCode also resets palette.
- File icon is not saved if it's a new file
- Custom Block Palette: inconsistent behavior about multi-line snippets HOT 1
- trying to install pencil code at my server and getting ERROR when run GRUNT HOT 3
- how to integrate g+ into pencilcode
- error [email protected] install: `node-gyp configure build HOT 1
- I can't install pencilcode. please help!
- How to insert new block?
- Thumbnail popover is a bit misaligned when a new thumbnail is created
- Something worng when run grunt HOT 1
- Blocks for adding elements to array
- Custom palette using guide requires user be logged in, making link sharing difficult
- Unable to type properly on mobile devices
- Error while running grunt HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pencilcode.