You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@pivot.apache.org by Greg Brannon <gr...@gmail.com> on 2012/09/25 23:35:34 UTC

First impressions of a wannabe adopter

Talented Pivot Developers, Users, and Supporters,

I like Apache Pivot, but I want to like it even more.  I want to know it.  I 
want to be able to use every class and method of it, explore it, know the ins 
and outs of it; know where it excels, what its limitations are, and  write a 
challenging project with it.  If I don't know how to do something with Pivot, 
I want to be able to click on a link or (if I have to) pick up a reference 
that has the info I need to figure it out.  But at the moment, my experience 
with Pivot has not left me with confidence that I can know Pivot well enough to 
be successful using it.

Believe me, I've tried.  I worked through every tutorial, writing minor 
variations for each, moving code around, using different components, exploring 
the various ways to write action handlers.  I used the Component Explorer, 
wondering, "Why aren't the major containers, like Window, Frame, Sheet, etc. 
included?"  I've studied the API, learning the details I could for most every 
element of the Framework I've used throughout the tutorial experience.

Then I struck out on my own.  I wrote some basic interfaces in bxml, toying 
with ideas I have for a project I'd like to write in Pivot.  Those went well, 
they looked okay, I've learned to like the bxml interface design approach - in 
fact, I don't want to give it up - but there were nagging questions I couldn't 
answer.  "Be patient," I told myself.  "Keep plodding along, and the details 
will come."

Then I gave myself an assignment I thought might answer some of the nagging 
questions: Take an interface I'd already designed in bxml and rewrite it 
completely in Java.  The interface included a Frame with a MenuBar, 2 
MenuBar.Items, each with a Menu with 2 Menu.Items, Border, TablePane with 
columns and rows, BoxPane, and a couple Expanders.  No function, just the 
shell of an interface.

I couldn't do it.  I tackled the task, incrementally writing each part in the 
same order as listed above but got stuck early on at the MenuBar and Menus.  I 
could not find the information I needed to accomplish what should be a 
relatively (I thought) simple thing.

I could accept that maybe it was a stupid idea.  Why write an interface 
completely in Java that can be defined easily in bxml?  I don't know.  Why not?  
Shouldn't I be able to?  Or if it's not possible, shouldn't that be documented 
somewhere?  I could have accepted it if I thought it were true, but I don't.  
So I walked away from Pivot, thinking what I wrote in the first paragraph.

So that I don't come across as  just a complainer, I'm volunteering.  I'm 
still excited about Pivot's potential, I believe in it and am impressed by 
Apache's projects overall, and I'll help in any way I can to improve Pivot's 
packaging to enable it to be more widely adopted.  But I shouldn't bound or 
limit my offer to help.  I'll simply do whatever I can to help, period.  Just 
let me know what I can do.

Until Pivot's documentation or usability improves, I'll work on my project 
using plain ol' Swing.

Greg Brannon
Hughesville, MD USA
(443) 684-2064

Re: First impressions of a wannabe adopter

Posted by Pavan Vadavalli <pa...@gmail.com>.
Hi Greg,
In your email,I can see some reflections of myself around an year back,
especially one of the things where you are blocked, to be able to playfully
move around bxml and java code and understand how this whole thing works

One approach that helped me a lot to move on and break open the chest of
puzzle was to debug the Pivot framework itself.

I wrote some simple Sysouts in the BXMLSerializer, to throw some light on
what it is doing , what properties its picking up , what setters its
invoking,while traversing the bxml and finally giving me the Object.

This helped me a lot to understand the intricacies without much needed
Pivot Documentation (btw, i believe code speaks more than Documentation,
just a personal belief)

Swing is ok, but your next steps towards java based GUI implementation Java
Fx also has the similar implementation of Bxml, (courtesy Greg Brown :))
and as time moves on...

Now my own project has around nice framework on the top of Pivot, has two
big implementations of this, has around 300+ BXML files + similar number of
code implementations, couple of Theme overrides.

I am currently prototyping a Caching Module to pool the GUI objects with
BXML as the Object Factory.

Well, i don't say it was easy but it was pretty worthwhile attempt i have
made to use the framework after around 3-4 months of looking around 5-6
options that provided Flexibility to create new or extending GUI
components, easier framework for Rich GUI applications deployable over
http, open source to name a few.

my sincere advice, just give it some more debugging to break it open and
you would suddenly realize, it becomes like a toy :)

I hope my experiences help ..
and Yes i do accept..Pivot has a long way to go..to make it more robust and
developer Friendly Framework..

Thanks and Regards,
Pavan


On Wed, Sep 26, 2012 at 7:35 AM, Greg Brannon <gr...@gmail.com>wrote:

> **
>
> Talented Pivot Developers, Users, and Supporters,
>
>
>
> I like Apache Pivot, but I want to like it even more. I want to know it.
> I want to be able to use every class and method of it, explore it, know the
> ins and outs of it; know where it excels, what its limitations are, and
> write a challenging project with it. If I don't know how to do something
> with Pivot, I want to be able to click on a link or (if I have to) pick up
> a reference that has the info I need to figure it out. But at the moment,
> my experience with Pivot has not left me with confidence that I can know
> Pivot well enough to be successful using it.
>
>
>
> Believe me, I've tried. I worked through every tutorial, writing minor
> variations for each, moving code around, using different components,
> exploring the various ways to write action handlers. I used the Component
> Explorer, wondering, "Why aren't the major containers, like Window, Frame,
> Sheet, etc. included?" I've studied the API, learning the details I could
> for most every element of the Framework I've used throughout the tutorial
> experience.
>
>
>
> Then I struck out on my own. I wrote some basic interfaces in bxml, toying
> with ideas I have for a project I'd like to write in Pivot. Those went
> well, they looked okay, I've learned to like the bxml interface design
> approach - in fact, I don't want to give it up - but there were nagging
> questions I couldn't answer. "Be patient," I told myself. "Keep plodding
> along, and the details will come."
>
>
>
> Then I gave myself an assignment I thought might answer some of the
> nagging questions: Take an interface I'd already designed in bxml and
> rewrite it completely in Java. The interface included a Frame with a
> MenuBar, 2 MenuBar.Items, each with a Menu with 2 Menu.Items, Border,
> TablePane with columns and rows, BoxPane, and a couple Expanders. No
> function, just the shell of an interface.
>
>
>
> I couldn't do it. I tackled the task, incrementally writing each part in
> the same order as listed above but got stuck early on at the MenuBar and
> Menus. I could not find the information I needed to accomplish what should
> be a relatively (I thought) simple thing.
>
>
>
> I could accept that maybe it was a stupid idea. Why write an interface
> completely in Java that can be defined easily in bxml? I don't know. Why
> not? Shouldn't I be able to? Or if it's not possible, shouldn't that be
> documented somewhere? I could have accepted it if I thought it were true,
> but I don't. So I walked away from Pivot, thinking what I wrote in the
> first paragraph.
>
>
>
> So that I don't come across as just a complainer, I'm volunteering. I'm
> still excited about Pivot's potential, I believe in it and am impressed by
> Apache's projects overall, and I'll help in any way I can to improve
> Pivot's packaging to enable it to be more widely adopted. But I shouldn't
> bound or limit my offer to help. I'll simply do whatever I can to help,
> period. Just let me know what I can do.
>
>
>
> Until Pivot's documentation or usability improves, I'll work on my project
> using plain ol' Swing.
>
>
>
> Greg Brannon
>
> Hughesville, MD USA
>
> (443) 684-2064
>



-- 
Thanks and Regards,
Pavan

Re: First impressions of a wannabe adopter

Posted by Sandro Martini <sa...@gmail.com>.
Hi all,
as Roger, I'd like to thank you for all the time dedicated to Pivot ...

Just some Info (I hope useful) from another point of view:
- usually in many open source products, the pain point is the
documentation, lack, outdated, or not so clear
  -- luckily here I think we need only to improve it, making it more
clear to new comers, and of course for this we need first some
feedback like this
  -- then we need to write it (in Javadoc inside sources, maybe with
dedicated tests, and maybe even with dedicated tutorials or samples,
and finally maybe updating even the web site) ... and as you know this
is a lot of work (usually done by me, but of course time is limited,
so if I do this I don't write code, but for me it's ok, as many knows
I'm not-so code-oriented :-) ... and there are some parts of Pivot
that still I know little like data binding
- we are bxml oriented, this is true, so maybe some simple (simple,
not trivial) example/tutorial on this could be good
  -- suggestions are welcome ...
- many times I get requests for fix/features, but it's a time
consuming process to better understand cusotmer needs, write a simple
test case to show the problem, before start looking at the fix
  -- even this is an area where help would be great


So in short:
any help anyone wants to give us is really welcome, and remember that
the code is only a small part (of course a critical part) of the
product.
During years in this project I have been doing many things (usability,
quality, web site pages and graphics, manage ci builds, manage jira,
manage release, publish release artifacts on maven repository, and
many other things ... ok, many only for PMC Members), and write
relatively small code (fix, new features/improvements, external
projects), etc ... but in open source I think this is good, anyone is
free to do a contribution depending on the knowledge, free time, and
interests; and there is no lower limit, anyone is free to do
something, when it has time, no deadlines, etc (generally speaking :-)
).
After some time/contribution to Pivot, a user could become a Committer
(Vote required by PMC) and get rights to commit in SVN repository, etc
... anyone of us has started from here, only some time and interest is
needed.
I can say that this is an interesting experience, from many points of
view, at least it is for me :-) .


To make this project alive we need the help and the continuous
feedback even from our users.
Swing are no more a future-proof investment, and JavaFX is stronger
any day, but I think that here we could continue to give a great
product, maybe see what feature to do, but this is another question
...


> I am currently prototyping a Caching Module to pool the GUI objects with BXML as the Object Factory.
this is interesting ... if you'd like to share with us, I could give
you grants for example in pivot-contrib (under apache-extras) so you
can put all in a new subproject, and if needed help you to have it
more aligned with our code base ... tell me if you like this

http://code.google.com/a/apache-extras.org/p/pivot-contrib/


Note:
for 2.1 we have many new ideas, and if someone has others too, tell to
us (there are already many JIRA issues for all this stuff).
For example, I'd like to start thinking/writing:
- some modular approach, to simplify/improve writing complex
applications (but in a simpler way that full OSGi support already in
plan, but for the future)
- a new skin (with a flat look and maybe using a lot hardware
transparencies etc, even to show better how to extend Pivot for custom
solutions and custom components) ... maybe for apache-extras


Bye,
Sandro

Re: First impressions of a wannabe adopter

Posted by Greg Brannon <gr...@gmail.com>.
@Pavan,

Thanks.  An inspiring testimonial.  After reading your response, I
feel a bit like the slacker I sometimes see in others who ask for help
with Core Java who haven't taken the time to do the basic research to
answer their own questions.  In my own defense, I would suggest that
the volume and variety of data available on Core Java is a large
multiple of that available for Pivot.  (Frankly, JavaFX isn't much
more accessible than Pivot, if at all.)

@Roger,

I understood very little of what you said.  On one hand, that inspires
me to dig further to try to understand your points about the
@DefaultProperty and the BXMLSerializer.  On the other, it causes me
to wonder if I'm up to the task.  Yep, I read  and mostly understand
the BXML Primer, but I haven't read the BXMLSerializer source code.
It's hard for me to imagine it to be a "fascinating read," but now I'm
curious.

@All,

I'm not working to a deadline and I don't have to understand the
framework completely within a certain timeframe, but I do have to see
there's a possibility that the tools exist to achieve near mastery of
the topic at some point in the not too distant future, say, within my
lifetime.  I'll try reading the source code to see if the Rosetta
Stone might be hidden there, but I thought that's what the API was
for.  Not everyone has the skill/talent or commitment/patience to
learn a complex technology by reading the source code.  I don't admit
it happily or easily, but I may be in that camp.  I definitely know
that I'm not the guy who can sit and stare at his inbox, waiting for
an answer to a technical question required to continue a project.

I accept that my experiences with Pivot are due to my own boundaries
and limitations, so don't judge the product or its worthiness for your
application by anything I've said. The product is impressive, and the
community is largely available and eager to help.

I'll be back after doing the additional study suggested by Pavan and Roger.

RE: First impressions of a wannabe adopter

Posted by "Roger L. Whitcomb" <Ro...@actian.com>.
Hi Greg,

                First of all, thanks for taking the time and initiative
to look at and study Pivot!  I was in your shoes not all that long ago
myself.  So, let me address a couple of your comments from my
experience:

* It is definitely possible to write anything you already have in BXML
in pure Java.  BXML is basically a reflection-based convenience
interface that is taking the XML representation and (via reflection)
creating the objects and setting attributes as it encounters them in the
markup.  So, ANYTHING you can do in BXML you can definitely do in pure
Java, because ultimately it IS being done in pure Java under the covers.

* But, having said that, sometimes there are some (fairly) hidden things
that are going on that are not immediately obvious.  One has to do with
the @DefaultProperty annotation on various classes (see Viewport for
instance).  This is used by BXML to decide how the child elements of an
element are to be wired to the parent.  If this property is present on a
class or its superclass, then by default the children will be set using
this property even if the property isn't directly coded in the XML.  For
instance, because of @DefaultProperty, you can write this:

<ScrollPane>

   <TextArea ...>

</ScrollPane>

Instead of having to code this:

<ScrollPane>

  <view>

    <TextArea ...>

  </view>

</ScrollPane>

* Another difficulty has to do with the way Menus are hooked up to
Frames.  This is done via the "setMenuBar" method, and thus looks like
this in BXML:

<Frame>

  <menuBar>

    <MenuBar>

      <MenuBar.Item...>

In pure Java, you would create a MenuBar object, and the call
"frame.setMenuBar(menuBarObject)".  This bxml is exactly a shortcut to
this Java sequence.  So, you see the XML elements that begin with lower
case are mapped to bean attributes on the parent object and set that
way, while elements that begin with UpperCase are mapped to actual Pivot
Java objects and instantiated with "class.newInstance(...)".  When new
child objects are encountered and there is a @DefaultProperty on the
parent, then the child/ren are set using that (which also means there
can be only one child object), otherwise the parent is assumed to
implement Sequence<Component> and the children are added via the
"add(component)" method.  If you really want to know more, the source
for BXMLSerializer is a fascinating read.   Did you read the BXML Primer
here http://pivot.apache.org/tutorials/bxml-primer.html (I'm sure you
did)?

* I very much agree that there are holes in the examples, documentation,
Javadoc, wiki, etc.  But, I found what is there to be extremely
valuable, and I still use the ComponentExplorer, the Javadoc and even
the tutorials on a regular basis. 

* So, one way that someone new could REALLY help is by filling in that
kind of information, or adding tutorials, responding to the user mailing
list, etc.  I never had a question in my early days with Pivot that
either somebody didn't answer, or that I couldn't figure out by looking
at the source.  And we'd be very happy to accept patches that improve
the new user experience J  And several of us really try to answer every
user inquiry as soon as possible (given that we have full-time jobs and
families too).

* It is VERY possible to write big production applications using Pivot.
We have released the first version of our product using it, with
~150,000 lines of code, and we now have 4 developers who are reasonably
to very proficient.

 

HTH, and please don't hesitate to ask if you don't understand something
- that's, in big part, how I learned.....

 

Thanks,

~Roger Whitcomb

 

From: Greg Brannon [mailto:greg.d.brannon@gmail.com] 
Sent: Tuesday, September 25, 2012 2:36 PM
To: user@pivot.apache.org
Subject: First impressions of a wannabe adopter

 

Talented Pivot Developers, Users, and Supporters,

 

I like Apache Pivot, but I want to like it even more. I want to know it.
I want to be able to use every class and method of it, explore it, know
the ins and outs of it; know where it excels, what its limitations are,
and write a challenging project with it. If I don't know how to do
something with Pivot, I want to be able to click on a link or (if I have
to) pick up a reference that has the info I need to figure it out. But
at the moment, my experience with Pivot has not left me with confidence
that I can know Pivot well enough to be successful using it.

 

Believe me, I've tried. I worked through every tutorial, writing minor
variations for each, moving code around, using different components,
exploring the various ways to write action handlers. I used the
Component Explorer, wondering, "Why aren't the major containers, like
Window, Frame, Sheet, etc. included?" I've studied the API, learning the
details I could for most every element of the Framework I've used
throughout the tutorial experience.

 

Then I struck out on my own. I wrote some basic interfaces in bxml,
toying with ideas I have for a project I'd like to write in Pivot. Those
went well, they looked okay, I've learned to like the bxml interface
design approach - in fact, I don't want to give it up - but there were
nagging questions I couldn't answer. "Be patient," I told myself. "Keep
plodding along, and the details will come."

 

Then I gave myself an assignment I thought might answer some of the
nagging questions: Take an interface I'd already designed in bxml and
rewrite it completely in Java. The interface included a Frame with a
MenuBar, 2 MenuBar.Items, each with a Menu with 2 Menu.Items, Border,
TablePane with columns and rows, BoxPane, and a couple Expanders. No
function, just the shell of an interface.

 

I couldn't do it. I tackled the task, incrementally writing each part in
the same order as listed above but got stuck early on at the MenuBar and
Menus. I could not find the information I needed to accomplish what
should be a relatively (I thought) simple thing.

 

I could accept that maybe it was a stupid idea. Why write an interface
completely in Java that can be defined easily in bxml? I don't know. Why
not? Shouldn't I be able to? Or if it's not possible, shouldn't that be
documented somewhere? I could have accepted it if I thought it were
true, but I don't. So I walked away from Pivot, thinking what I wrote in
the first paragraph.

 

So that I don't come across as just a complainer, I'm volunteering. I'm
still excited about Pivot's potential, I believe in it and am impressed
by Apache's projects overall, and I'll help in any way I can to improve
Pivot's packaging to enable it to be more widely adopted. But I
shouldn't bound or limit my offer to help. I'll simply do whatever I can
to help, period. Just let me know what I can do.

 

Until Pivot's documentation or usability improves, I'll work on my
project using plain ol' Swing.

 

Greg Brannon

Hughesville, MD USA

(443) 684-2064