What is your favorite explicit configuration? Am 21.02.2014 16:49 schrieb "Brian LeRoux" <b...@brian.io>:
> As much as I'd like a single icon source I do not think it is the right > path. To do this right I think we need to audit all possible icons for each > platform and create a map to analyze what could be distilled across > platforms. > > Ideally we'd accept a vector format (SVG) and generate all these ridiculous > sizes but designers will not like this. Pixel perfection, especially for a > springboard icon, is paramount. The only way we're getting there safely is > zero magic and explicit configuration. > > Lame, I know. > > > On Thu, Feb 20, 2014 at 1:07 AM, Axel Nennker <ignisvul...@gmail.com> > wrote: > > > How about this strategy: > > > > project_dir/config.xml > > - no new elements in config.xml like cdv:icon > > - no new attributes in icon element in config.xml like cdv:platform or > > gap:platform > > - do not invent stuff we have to support for the rest of our life. > > > > On all platforms: > > - if config.xml contains a <icon src="whatever.png"/> without any > > attributes like width and heigth, then copy that src to to all platform > > specific locations where that platform expects launcher icons and update > > config files like manifest.webapp on FirefoxOS if there isn't a specific > > icon element for that location (see later). > > - no downscaling of icons to lower sizes > > - no upscaling of icons to higher sizes > > - do not add dependencies to new node modules (e.g. to parse icon files) > > > > On Android: > > I) if there is a specific <icon src="icon.png" width="48" /> then copy > > that icon.png to res/drawable-mdpi (height is ignored if width is > present, > > no check for non-sqare icons) > > II) Other sizes are handled according to this list from: > > http://developer.android.com/guide/practices/screens_support.html > > > > - 36x36 for low-density > > - 48x48 for medium-density > > - 72x72 for high-density > > - 96x96 for extra high-density > > > > Directories not matching this algorithm that have names starting with > > res/drawable get the biggest icon if no default icon is available (I). > > III) icons with width or height other than the ones mentioned here are > > ignored. > > > > On FirefoxOS: > > See https://developer.mozilla.org/en-US/Apps/Developing/Manifest#icons > > > > For Firefox OS, icons should follow the app icon > > guidelines< > > https://www.mozilla.org/en-US/styleguide/products/firefox-os/icons/>, > > they should not have a drop shadow, and they should be in the following > > sizes: > > 128 x 128 For display on the Firefox Marketplace 60 x 60 For the actual > > on-device icon; only the 128px icon is mandatory, but it is recommended > to > > include this size as well for optimal device icon display > > https://www.mozilla.org/en-US/styleguide/products/firefox-os/icons/ > > > > I) ignore icon elements in config.xml without width or height attributes > > II) copy all icons mentioned in config.xml with width or height equal to > > 60 or 128 to the app's root and create an icon section in manifest.webapp > > that matches these icons. > > III) if no icon is specified for width/height 60 or 128 then copy each > icon > > mentioned in config.xml that has width or height specified. > > > > On other platforms: > > some strategy matching the ones for Android and FirefoxOS. If a size is > > there that is typical for that platform (72,144 for ios) then us only > those > > matching icons. Try to help developers. > > > > -Axel > > > > > > > > > > > > > > > > 2014-02-13 9:56 GMT+01:00 Axel Nennker <ignisvul...@gmail.com>: > > > > > The topic is reaching politics status... > > > > > > I think it is worth some effort to keep phonegap and cordova aligned. > > > What is "Adobe"'s position on W3C widget and xml vs json? > > > > > > -Axel > > > > > > Regarding which PR to accept: I want support for launcher icons and I > do > > > not care whether my PR is accepted or the other one. > > > Actually I do not understand why CB-2606 is open for so long. > > > https://issues.apache.org/jira/browse/CB-2606 > > > > > > > > > > > > > > > 2014-02-12 23:33 GMT+01:00 Jesse <purplecabb...@gmail.com>: > > > > > > Part of what you are seeing is the phonegap namespace extensions that > are > > >> added for build.phonegap.com and the online tools. [1] [2] > > >> > > >> > > >> [1] > > >> > > >> > > > http://docs.build.phonegap.com/en_US/3.1.0/configuring_basics.md.html#The%20Basics > > >> [2] > > https://github.com/phonegap/phonegap-start/blob/master/www/config.xml > > >> > > >> > > >> @purplecabbage > > >> risingj.com > > >> > > >> > > >> On Wed, Feb 12, 2014 at 2:03 PM, Andrew Grieve <agri...@chromium.org> > > >> wrote: > > >> > > >> > Just started a new thread to propose removing the namespace. > > >> > > > >> > Don't the we should use "gap:density", since that's pretty > PhoneGap-y > > as > > >> > opposed to Cordova-y. > > >> > > > >> > How about we have "size" and "density" attributes that are just > > >> synonyms? > > >> > > > >> > Off for the day. > > >> > > > >> > > > >> > > > >> > On Wed, Feb 12, 2014 at 4:57 PM, Axel Nennker < > ignisvul...@gmail.com> > > >> > wrote: > > >> > > > >> > > Hm. I guess the id test is historical stuff. It is legal XML and > the > > >> > parser > > >> > > ignores it. > > >> > > > > >> > > Regarding the NS prefix: cdv vs gap > > >> > > I am quite sure I did not invent cdv myself. > > >> > > > > >> > > Regarding the w3c widget standard: I am OK with ditching it. > Should > > >> there > > >> > > be a poll or how do you handle such things? > > >> > > All app templates should remove namespaces then, right? > > >> > > > > >> > > Isn't there another thread around namespaces breaking the wp > > platform? > > >> > > > > >> > > Anyway, I think we should follow the phonegap way with e.g > > >> gap:density > > >> > for > > >> > > now. And ditch namespaces later. > > >> > > > > >> > > Axel > > >> > > Am 12.02.2014 22:38 schrieb "Andrew Grieve" <agri...@chromium.org > >: > > >> > > > > >> > > > On Tue, Feb 11, 2014 at 3:43 PM, Brian LeRoux <b...@brian.io> > wrote: > > >> > > > > > >> > > > > Given we are the only 'widget spec' impl in use today I'm ok > > with > > >> > > > diverging > > >> > > > > and not adding namespace confusion. Def want config to be > > explicit > > >> > and > > >> > > > not > > >> > > > > have magical implicit mappings. > > >> > > > > > > >> > > > > > > >> > > > > On Tue, Feb 11, 2014 at 12:24 PM, Axel Nennker < > > >> > ignisvul...@gmail.com > > >> > > > > >wrote: > > >> > > > > > > >> > > > > > - My implementation does not use "id". Don't know what this > or > > >> > might > > >> > > > > mean. > > >> > > > > > > >> > > > Found it from your test in spec/test-config.xml > > >> > > > > > >> > > > > > >> > > > > > - I do not want to discuss the sense of xml namespaces in > > this > > >> > issue > > >> > > > if > > >> > > > > we > > >> > > > > > can avoid it. The current template config.xml defines two > > >> > namespaces > > >> > > > and > > >> > > > > > for this issue's implementation I do not want to change > that. > > >> So I > > >> > > > would > > >> > > > > > not drop the widget namespace and would not support > > >> > > > > > "platform"-without-prefix. > > >> > > > > > > >> > > > > > >> > > > Having gap:platform there makes the property seem like an > > >> second-class > > >> > > > maybe-not-supposed-to-be-there kind of attribute to me. > > >> > > > I'd be happy to change the default template to not reference the > > >> widget > > >> > > > spec and to make cordova's the default namespace if that will > make > > >> your > > >> > > > inner XML validator rest at-ease, but I really feel strongly > > against > > >> > > having > > >> > > > XML namespaces creep in. I don't think that most devs know what > > they > > >> > do, > > >> > > > and our tools wouldn't support you changing the gap: namespace > > >> prefix. > > >> > > > > > >> > > > > > >> > > > > > >> > > > > > - I would follow the phonegap example > > >> > > > > > > > >> > > > > > > > >> > > > > > > >> > > > > > >> > > > > >> > > > >> > > > http://docs.build.phonegap.com/en_US/3.1.0/configuring_icons_and_splash.md.html#Icons%20and%20Splash%20Screens > > >> > > > > > that defines e.g. " > > >> > > > > > > > >> > > > > > <icon src="icons/android/ldpi.png" gap:platform="android" > > >> > > > > > gap:density="ldpi" /> > > >> > > > > > > > >> > > > > > " and I would like to don't parse the icon file to infer > > >> > parameters. > > >> > > > > > Developers want need icons for their app on all platforms > they > > >> > > support. > > >> > > > > So > > >> > > > > > they will create all of them in all polished sizes and > > >> densities. > > >> > > > > > My Android implementation puts icons without cdv:density > into > > >> > > > > > "drawable/icon.png" regardless of width/height. > > >> > > > > > What behaviour would you suggest when both lines are present > > in > > >> one > > >> > > > > > config.xml > > >> > > > > > <icon src="icon48.png" width="48" cdv:platform="android" /> > // > > >> > would > > >> > > > end > > >> > > > > up > > >> > > > > > in drawable-mdpi by your suggestion > > >> > > > > > <icon src="icon-mdpi.png" cdv:density="mdpi" > > >> cdv:platform="android" > > >> > > /> > > >> > > > // > > >> > > > > > would end up in drawable-mdpi too > > >> > > > > > > >> > > > > > >> > > > My thinking here was that density says the same thing as size, > so > > I > > >> > would > > >> > > > just not support density (or make size="mdpi" an alias for > > >> size="48"). > > >> > > > > > >> > > > > > >> > > > > > >> > > > > > > > >> > > > > > I think that developers know what is the "platform-way" for > > each > > >> > > > > platform. > > >> > > > > > On Android the usual way is to specify densities. > > >> > > > > > > > >> > > > > > - I would not use "size" because that is not w3c widget > style. > > >> > > > > > > > >> > > > > > -- Axel > > >> > > > > > > > >> > > > > > > > >> > > > > > > > >> > > > > > 2014-02-11 20:22 GMT+01:00 Andrew Grieve < > > agri...@chromium.org > > >> >: > > >> > > > > > > > >> > > > > > > Would love to move this along. Would like to get buy-in > from > > >> > others > > >> > > > > > > first though. > > >> > > > > > > > > >> > > > > > > The proposal in this PR is to add tags like: > > >> > > > > > > > > >> > > > > > > <icon id="icon" src="icon.png" /> > > >> > > > > > > <icon id="logo" src="logo.png" width="255" > height="255" > > /> > > >> > > > > > > <icon src="logo-android.png" width="255" height="255" > > >> > > > > > > cdv:platform="android" cdv:density="mdpi" /> > > >> > > > > > > > > >> > > > > > > My feedback: > > >> > > > > > > - What is "id" for? > > >> > > > > > > - Supporting "cdv:platform" is fine, but we should also > > >> support > > >> > > just > > >> > > > > > > "platform=". I'd be fine to drop xmlns=" > > >> > > http://www.w3.org/ns/widgets > > >> > > > " > > >> > > > > > > from the file. > > >> > > > > > > - I don't think there are any platforms that support > > >> non-square > > >> > > > icons. > > >> > > > > > > I think size="###" would be better than width= && height= > > >> > > > > > > - What happens if you don't specify a size? Do we sniff it > > >> from > > >> > the > > >> > > > > > > png header? This might be nice as a follow-up, but I'd > lean > > >> > towards > > >> > > > > > > making it required for the first cut. > > >> > > > > > > - cdv:density seems redundant with respect to size. Icons > on > > >> > > android > > >> > > > > > > are 46px at mdpi, so the size can be used to derive the > > >> density. > > >> > > > > > > > > >> > > > > > > > > >> > > > > > > On Mon, Feb 10, 2014 at 10:55 AM, Andrew Grieve < > > >> > > > agri...@chromium.org> > > >> > > > > > > wrote: > > >> > > > > > > > He Axel, thanks for spearheading this. Will have a look > > >> > shortly. > > >> > > > > > > > > > >> > > > > > > > > > >> > > > > > > > On Mon, Feb 10, 2014 at 9:07 AM, Axel Nennker < > > >> > > > ignisvul...@gmail.com > > >> > > > > > > > >> > > > > > > wrote: > > >> > > > > > > >> > > >> > > > > > > >> Andrew, > > >> > > > > > > >> > > >> > > > > > > >> any comments to the current implementation? > > >> > > > > > > >> https://github.com/apache/cordova-cli/pull/126 > > >> > > > > > > >> > > >> > > > > > > >> Joe commented that the new class in config_parser.js > > named > > >> > > "icon" > > >> > > > > > should > > >> > > > > > > >> be named "Icon" but I left it as is because the other > > >> classes > > >> > > are > > >> > > > > > > lowercase > > >> > > > > > > >> too. > > >> > > > > > > >> There was another comment that namespaces in config.xml > > >> > > attributes > > >> > > > > are > > >> > > > > > > >> SchnickSchnack/chatter. > > >> > > > > > > >> I think that we should use the cordava namespace if > > >> config.xml > > >> > > > > > deviates > > >> > > > > > > >> from the W3C widget definition. > > >> > > > > > > >> These two are the only comments I got. > > >> > > > > > > >> > > >> > > > > > > >> I tested this on Android and FirefoxOS. > > >> > > > > > > >> > > >> > > > > > > >> Any chance to accept the request (at least the Android > > >> part)? > > >> > > > > > > >> > > >> > > > > > > >> -Axel > > >> > > > > > > >> > > >> > > > > > > > > > >> > > > > > > > > >> > > > > > > > >> > > > > > > >> > > > > > >> > > > > >> > > > >> > > > > > > > > >