Air 3 for Mobile - StageText example? - apache-flex

Air 3 for mobile introduces a nice feature - StageText. I have seen a few videos showing what the end result looks like, but I cannot find how to actually implement it in code.
There is this page here, however, when trying to add the extra properties to the s:TextInput elements, I only get errors. Obviously, something is missing.
Anyone out there have any hints or working examples?
Thanks!

The new TextInput enhancements are part of the Flex 4.6 SDK which has not been released yet (as of 11/3/2011). If you want access to it right now, you need to sign up for the pre-release program.

Related

MVC 4 mobile styles stopped working after script update

I'm trying to learn ASP.NET MVC programming. I've been using default MVC 4 mobile application template for my experiments. At some point I've decided to update the scripts to their latest versions (from 1.1.1 to 1.2.0 in case of jquery-mobile). For some reason the styling of the page is now gone. I know that this has nothing to do with my changes since I'm pretty much made none, so it has to be solely due to update. I was wondering if someone could point out to me what should I look at in order to figure out this problem, because honestly, at the moment I'm completely lost and don't even have a clue where to start looking or how to "debug" these kinds of problems. There's just too many "magic strings" in this template for me to wrap my head around.
Oh, just use lower jQuery version.
jQuery Mobile 1.2 dont work with jQuery 1.9.1 and above. They have locked 1.2 to use jQuery versions from 1.6.4 up to 1.8.2.
Proof :
Take a look at this jsFiddle example: http://jsfiddle.net/Gajotres/yWTG2/, change jQuery version in top left corner and see a difference. Don't forge to run it after change.
With version 1.9.1. you will get something like this:
First Page
Next
Second Page
Back

Is Flex Label baselineshift supported on mobiles?

I need to create subscript text for mobile. I read at http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/spark/components/Label.html that label's baselineShift property is not supported on the mobile theme. So I created a plain mobile project using the default mobile theme with a couple of test labels and in the FB 4.5 emulator the baselineshift worked fine.
Why then do they say that it's not supported? Is there anything to stop me going ahead and using it?
It doesn't sound like here is anything to prevent you from using it. When something like this isn't "supported" it generally means that Adobe is afraid of performance issues that may result in using this.

JavaFX Datagrid

Im in the verge of starting a new RIA development. We've been using Flex/Flash for the last 2 years but we were considering using a more OS approach so we though giving JavaFX a try since it seams the only solid option available. However after a couple of days of research we found out that there is not such thing as a datagrid for it, at least not in the core API. For those unfamiliar with Flex, a Datagrid is a component that allows you to display a collection of data in column-row layout (much like a HTML Table on steroids). The beauty of it is that you only need to worry about the data itself as the component does pretty much the rest (sorting, column dragging, etc).
Im afraid to ask... but is there something slightly similar for JavaFX?
We require nothing as fancy as Flex Datagrids/AdvancedDatagrids, we only require a easy, straight forward way to display grids of data that are able to have a little of interaction like clicking, sorting and that are able to display images, buttons, etc. without having to download a ton of different jars.
If there isnĀ“t something out there... This would be a shot in the back of the head to the idea of giving javaFx the chance to compete with flash on our project (which is sad).
I really cant believe the SUN people didnt include something like this on the core API...
There is currently no datagrid you can use JTable for that. Such a thing should be available in the next release of JavaFX I think. See my answer here for more information about available JTable implementations. You mentioned the JFXtras project with that you are able to embed those Swing components into JavaFX.
There are external companies selling such a component. E.g. do a web search or look here
For apache pivot you should ask them directly for the pros and cons; they are very responsive and honest.

Flex printing on OSX pushes image off the page. How can this be fixed?

My Flex 3 app prints pages just fine from browsers on Windows using FlexPrintJob (not the browser print function). However, on OSX, the left and top margins show up larger and the page gets pushed off the right and bottom. Basically, the scaling is screwed up, and I can't see any way to adjust the margins in code.
Has anyone seen this discrepancy in Flex printing between Windows and OSX? Are there any known workarounds? I've searched all over and I can't find any good info on this (other than 12 unresolved printing bugs in the Adobe Jira DB).
And please don't say "don't print in Flex". I know Flex sucks at printing, but I have to use it. Thanks!
Edit:
PDF Generation is one route and while its a valid solution for some folks, I need to print directly. I'd like to see stuff like using regular Flash PrintJob, monkeypatches to FlexPrintJob, or just ways I can format my DisplayObjects before sending them to FlexPrintJob. None of the scaling options in FlexPrintJob work. My Flex Component is at 1.0 scale. I'm not sure what else I can do except for mess around with regular PrintJob. I'm putting a bounty on this for answers in this domain.
Switch to PDF generation. There are two ways to do this without having to purchase server-side licenses:
Use our library of Flex components - clear.swc, a part of open source Clear Toolkit available on Sourceforge. This process is described in Ch. 11 of the book Enterprise Development with Flex currently available as rough cuts on safaribooksonline.com
Use open-source library alivePDF.
Don't print by Flex PrintJob :)

What features do you need the most in Adobe Air?

I recently started to develop using Flex 3 and Adobe Air and I wanted to know what features you want to be in futures releases of Adobe Air ?
The ones that I miss are:
Cross-systems way of launching a local file (shellExec) right from an Air application (although you can do this using workaround at least under Windows)
Ability to setup dynamic paths for Embed statement (e.g. Embed[(variable+"/path/to/file")] ). I didn't find any way to do this properly.
Some way of setting Flex object's positions with absolute values from CSS (that sounds more Flex related by the way)
Don't hesitate to add your workarounds to theses limitations if you know somes.
Ability to call out to native code - you currently have to ship a server written in another language and make calls to that to do anything more than Air gives you.
Modal windows. There's a hack you can do which involves setting Application.application.enabled = false, setting dialog.nativeWindow.alwaysInFront = true and then re-enabling the application when the dialog closes, but this is long-winded and doesn't disable any native menus you may have! It's crazy that something so simple is made so difficult.
A usable way to set the application's icon. I spent 2 hours trying to do this the other day and gave up after persistent "303" errors that gave me no idea of what I was doing wrong. Again, really basic stuff.
"Call native code", "Modal windows", agree-agree.
loadLibrary would be really great :)
ps.:
if we can not have this features in AIR, if would be awesome to have an opportunity to embed flash(AIR) graphics engine into your own app. in that case we'll get great performance improvement and liberty of choice what to write (not only small gadgets).

Resources