Loading font from external website

General discussion of development ideas and the approaches taken in the 3.x branch of phpBB. The current feature release of phpBB 3 is 3.3/Proteus.
Forum rules
Please do not post support questions regarding installing, updating, or upgrading phpBB 3.3.x. If you need support for phpBB 3.3.x please visit the 3.3.x Support Forum on phpbb.com.

If you have questions regarding writing extensions please post in Extension Writers Discussion to receive proper guidance from our staff and community.
User avatar
Marc
Development Team Leader
Development Team Leader
Posts: 191
Joined: Thu Sep 09, 2010 11:36 am
Location: Munich, Germany

Re: Loading font from external website

Post by Marc »

I like the new font and don't see a proper reason why we shouldn't try loading the Open Sans font from Google. A browser falls back to the next available font very easily.

+1 from me

User avatar
imkingdavid
Registered User
Posts: 1050
Joined: Thu Jul 30, 2009 12:06 pm

Re: Loading font from external website

Post by imkingdavid »

I'm fine with using the external source.
I do custom MODs. PM for a quote!
View My: MODs | Portfolio
Please do NOT contact for support via PM or email.
Remember, the enemy's gate is down.

User avatar
nextgen
Registered User
Posts: 128
Joined: Sat Jul 24, 2010 4:59 am
Location: Guatemala
Contact:

Re: Loading font from external website

Post by nextgen »

I like the idea raised by Arty, also would be essential to add a similar font if someone did not have access to the internet, either to do testing on localhost without internet.
*Imagine a signature super spectacular.*

User avatar
Arty
Former Team Member
Posts: 985
Joined: Wed Mar 06, 2002 2:36 pm
Location: Mars
Contact:

Re: Loading font from external website

Post by Arty »

Somewhat related news: http://blog.mozilla.org/blog/2013/05/14 ... rovements/

Firefox for Android now includes Open Sans font.

keith10456
Registered User
Posts: 523
Joined: Sat Apr 22, 2006 10:29 pm
Contact:

Re: Loading font from external website

Post by keith10456 »

I generally don't like depending on an external source. However, since the button/font would default to something if the external source becomes unavailable (as opposed to not having a button at all) then I think it's a good solution.

+1

User avatar
bantu
3.0 Release Manager
3.0 Release Manager
Posts: 557
Joined: Thu Sep 07, 2006 11:22 am
Location: Karlsruhe, Germany
Contact:

Re: Loading font from external website

Post by bantu »

Loading stuff from external sources should be a setting that is off by default due to privacy reasons.

Maybe we should just make a very generic "allow loading files from external sources" switch that is also used for jQuery etc. and ask for it during install.

If Firefox ships this font now, a lot of people can already use it. Or is that limited to the Android version?

User avatar
Arty
Former Team Member
Posts: 985
Joined: Wed Mar 06, 2002 2:36 pm
Location: Mars
Contact:

Re: Loading font from external website

Post by Arty »

That's limited to Android version.

Problem with enabling/disabling it is CSS isn't parsed. I think parsing CSS would be very good, but its too late for 3.1 because its too complex and proper implementation requires overhaul of template system that has been incorrectly designed from start.

User avatar
callumacrae
Former Team Member
Posts: 1046
Joined: Tue Apr 27, 2010 9:37 am
Location: England
Contact:

Re: Loading font from external website

Post by callumacrae »

+1 - I think the button looks pretty weird as it is, and including external assets isn't really a problem any more.
Made by developers, for developers!
My blog

User avatar
DionDesigns
Registered User
Posts: 51
Joined: Sat Apr 21, 2012 4:29 am
Location: Uncertain due to momentum
Contact:

Re: Loading font from external website

Post by DionDesigns »

callumacrae wrote:+1 - I think the button looks pretty weird as it is, and including external assets isn't really a problem any more.
What looks weird are the images to the right of the button text. They serve no purpose other than adding additional resource demands to the page -- and, I suppose, the fact that "they were there before, so they must be there now".

I agree that Verdana is a poor font choice for buttons...but Open Sans isn't much better. It's a "poor man's version" of Droid Sans, and it is missing the hints and superior kerning of Droid Sans (the font upon which it was based) and most built-in fonts. I'd suggest using Arial for most systems, and Droid Sans for Android-based systems. Here's the relevant rule in buttons.css:

Code: Select all

/* Rolloff state */
.buttons div a {
	display: inline-block;
	line-height: 17.5px;
	height: 18px;
	font-size: 13px;
	white-space: nowrap;
	border: 1px solid transparent;
	border-radius: 4px;
	background: transparent none 0 0 repeat-x;
	padding: 2px 22px 2px 8px;
	font-family: Verdana, Arial, Helvetica;
	position: relative;
	text-decoration: none !important;
	outline-style: none !important;
	vertical-align: bottom;
	*padding-right: 8px;
}
I suggest changing it to:

Code: Select all

/* Rolloff state */
.buttons div a {
	display: inline-block;
	line-height: 17.5px;
	height: 18px;
	font-size: 14px;
	white-space: nowrap;
	border: 1px solid transparent;
	border-radius: 4px;
	background: transparent none 0 0 repeat-x;
	padding: 2px 22px 2px 8px;
	font-family: Arial, "Droid Sans", sans-serif;
	font-weight: bold;
	letter-spacing: -0.3px;
	position: relative;
	text-decoration: none !important;
	outline-style: none !important;
	vertical-align: bottom;
	*padding-right: 8px;
}
And here is what the change would look like...the first button is the current rule, the second is the revised rule with Arial, and the third is the revised rule with Droid Sans.
bb31.png
bb31.png (3.03 KiB) Viewed 17333 times

User avatar
hanakin
Front-End Dev Team Lead
Front-End Dev Team Lead
Posts: 968
Joined: Sat Dec 25, 2010 9:02 pm
Contact:

Re: Loading font from external website

Post by hanakin »

ok u have that backwards if you wish droid sans to ever be used it has to come first in the stack. I do agree though if we do end up serving some font from google droid sans is far better than open sans and the icons for the buttons are kind of pointless as they add no visual understanding of the function of the buttons other than the lock icon. we should consider removing them or updating them to be better understood. The problem is not all the buttons really need this extra clarity.
Donations welcome via Paypal Image

Post Reply