You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@shindig.apache.org by Darren Bond <db...@globalcad.com> on 2013/09/18 09:24:24 UTC

Rendered Gadget Display Scrollbars unlike iGoogle

 Dear All,   We have a Shindig implementation and render our gadgets on a 
page using an ASP.NET wrapper.   When comparing how our gadgets render in 
comparison with the same gadgets on iGoogle, we tend to get content 
shifting and the introduction of vertical/horizontal scrolls bars. iGoogle 
avoids these issues somehow.   A sample screenshot can be seen here 
http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of a 
workaround?    Many thanks.   Darren 

RE: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Darren Bond <db...@globalcad.com>.
Hi Stanton/Dan,

Thank you for your helpful replies. I've received the following feedback
from our developer:-

Some gadgets get rendered correctly such as the TODO list gadget
(http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.

For example, we have problems with the Dictionary gadget
(http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
appears fickle in that sometimes vert/horiz scroll bars appear under home
view and at other times not.

All of them have <Require feature="dynamic-height"/> in their specification.
We use CSS padding for the html div tag that holds iframe coming from
Shindig. Looking at the JavaScript source code used to render the gadget:-

CommonContainer.renderGadget = function (gadget, contentHolder,
userPreference) {
    var gadgetURL = gadget.Url;
    var el = $(contentHolder).get(0);
    var params;
    if (userPreference == null) {
        params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
    } else {
        params = { userPrefs: userPreference };
    }
    params["view"] = "home";
    if (gadget.viewType == GadgetViewTypes.Canvas) {
        params["view"] = "canvas";
    }
    params[osapi.container.RenderParam.WIDTH] = '100%';
    var gadgetSite = CommonContainer.newGadgetSite(el);
    CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
    defaultUserPreference = {};
    return gadgetSite;
}; 

Any thoughts as to how we can improve things?

Kind regards,

Darren


-----Original Message-----
From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of Stanton
Sievers
Sent: 18 September 2013 16:34
To: users@shindig.apache.org; dev@shindig.apache.org
Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle

+ dev list

Are you using dynamic height or width features in your gadget?

Are the height and width properties set in your ModulePrefs? If so, what
are they set to and are both containers honoring those values when
rendering?

Thanks,
-Stanton
On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:

>  Dear All,   We have a Shindig implementation and render our gadgets on a
> page using an ASP.NET wrapper.   When comparing how our gadgets render in
> comparison with the same gadgets on iGoogle, we tend to get content
> shifting and the introduction of vertical/horizontal scrolls bars. iGoogle
> avoids these issues somehow.   A sample screenshot can be seen here
> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
> a
> workaround?    Many thanks.   Darren
>



Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Dan Dumont <dd...@apache.org>.
Shindig takes the approach of shifting render space management of the
gadget contents to the gadget.  The container may or may not support
increasing or decreasing available gadget space through apis like
dynamic-height and dynamic-width.  It also may choose to ignore the amount
of space requested by the gadget's view in the view declaration.

In new versions of shindig (and particular for html5 type gadgets) css is
injected into the gadget that sets html and body tags to width:100%,
height:100% and scrolling:auto.

Not sure if any of this is really impacting your gadget though, since it
looks like you're probably styling your main content to use the full width
of the gadget.
It may be that your css is using margins (instead of padding), setting
width to 100%, and therefore pushing the elements beyond the available
space.

I'd recommend using padding (if you're not already), and
box-sizing:border-box; so that padding will not extend the actual element
width beyond the specified width (100%).

On Wed, Sep 18, 2013 at 11:33 AM, Stanton Sievers <ss...@apache.org>wrote:

> + dev list
>
> Are you using dynamic height or width features in your gadget?
>
> Are the height and width properties set in your ModulePrefs? If so, what
> are they set to and are both containers honoring those values when
> rendering?
>
> Thanks,
> -Stanton
> On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
>
> >  Dear All,   We have a Shindig implementation and render our gadgets on a
> > page using an ASP.NET wrapper.   When comparing how our gadgets render
> in
> > comparison with the same gadgets on iGoogle, we tend to get content
> > shifting and the introduction of vertical/horizontal scrolls bars.
> iGoogle
> > avoids these issues somehow.   A sample screenshot can be seen here
> > http://download.globalcad.com/Gadget_Appearance.png   Does anyone know
> of
> > a
> > workaround?    Many thanks.   Darren
> >
>

Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Ryan Baxter <rb...@gmail.com>.
Dan knows best, he made that change ;)

If you want to change this behavior should be able to inject a
GadgetRewriter similar to the GadgetRenderingRewriter that is adding
the styles today.

On Tue, Oct 8, 2013 at 4:49 PM, Dan Dumont <dd...@apache.org> wrote:
> Again, this is there so that gadgets take ownership of the dom size they
> are given to render in.
>
> You likely have a margin/padding that is unintentionally pushing the
> content of the html/body outside of the bounds of what is available for
> your gadget, otherwise the html/body inside the iframe would not be
> scrolling.
>
>
> On Tue, Oct 8, 2013 at 4:39 PM, Darren Bond <db...@globalcad.com> wrote:
>
>> Hi Ryan,
>>
>> Relating to the unwanted scrollbars, our developer has come up with the
>> following findings:-
>>
>> In the beginning of each gadget Shindig library puts some small bit of CSS
>> code. It looks like this:
>>
>> html, body {
>> height: 100%;
>> overflow: auto;
>> width: 100%;
>> }
>>
>> It's hard to say why this gets injected. For me it looks unnecessary to
>> have
>> such properties for each gadget by default. iGoogle doesn't inject anything
>> similar and when I tried to put this piece of code on iGoogle (in Firebug)
>> same scrollbars appeared there. The problem can be easily solved by
>> resetting these properties back to default in the gadget's body. Of course
>> it is valid only for those gadgets whose code can be controlled by us.
>> Third-party gadgets which happened to have those scrollbars will keep them.
>>
>> Ryan are you able to shed some light on this injection of css code and
>> whether it can be removed?
>>
>> Kind regards,
>>
>> Darren
>>
>>
>> -----Original Message-----
>> From: Ryan Baxter [mailto:rbaxter85@gmail.com]
>> Sent: 24 September 2013 18:34
>> To: users@shindig.apache.org
>> Cc: dev@shindig.apache.org
>> Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>>
>> Can you reproduce the issues the sample common container in Shindig?
>> Or better yet build us a simple container that can reproduce the
>> issue?
>>
>> On Sun, Sep 22, 2013 at 3:12 PM, Darren Bond <db...@globalcad.com> wrote:
>> > Hi All,
>> >
>> > Unfortunately we're still struggling with this issue.
>> >
>> > Can anyone give us some helpful pointers where we might be going wrong
>> with
>> > the code below?
>> >
>> > Thanks.
>> >
>> > Darren
>> >
>> >
>> > -----Original Message-----
>> > From: Darren Bond [mailto:dbond@globalcad.com]
>> > Sent: 19 September 2013 09:24
>> > To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
>> > Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle
>> >
>> > Hi Stanton/Dan,
>> >
>> > Thank you for your helpful replies. I've received the following feedback
>> > from our developer:-
>> >
>> > Some gadgets get rendered correctly such as the TODO list gadget
>> > (http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.
>> >
>> > For example, we have problems with the Dictionary gadget
>> > (http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
>> > The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
>> > appears fickle in that sometimes vert/horiz scroll bars appear under home
>> > view and at other times not.
>> >
>> > All of them have <Require feature="dynamic-height"/> in their
>> specification.
>> > We use CSS padding for the html div tag that holds iframe coming from
>> > Shindig. Looking at the JavaScript source code used to render the
>> gadget:-
>> >
>> > CommonContainer.renderGadget = function (gadget, contentHolder,
>> > userPreference) {
>> >     var gadgetURL = gadget.Url;
>> >     var el = $(contentHolder).get(0);
>> >     var params;
>> >     if (userPreference == null) {
>> >         params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
>> >     } else {
>> >         params = { userPrefs: userPreference };
>> >     }
>> >     params["view"] = "home";
>> >     if (gadget.viewType == GadgetViewTypes.Canvas) {
>> >         params["view"] = "canvas";
>> >     }
>> >     params[osapi.container.RenderParam.WIDTH] = '100%';
>> >     var gadgetSite = CommonContainer.newGadgetSite(el);
>> >     CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
>> >     defaultUserPreference = {};
>> >     return gadgetSite;
>> > };
>> >
>> > Any thoughts as to how we can improve things?
>> >
>> > Kind regards,
>> >
>> > Darren
>> >
>> >
>> > -----Original Message-----
>> > From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of
>> Stanton
>> > Sievers
>> > Sent: 18 September 2013 16:34
>> > To: users@shindig.apache.org; dev@shindig.apache.org
>> > Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>> >
>> > + dev list
>> >
>> > Are you using dynamic height or width features in your gadget?
>> >
>> > Are the height and width properties set in your ModulePrefs? If so, what
>> > are they set to and are both containers honoring those values when
>> > rendering?
>> >
>> > Thanks,
>> > -Stanton
>> > On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
>> >
>> >>  Dear All,   We have a Shindig implementation and render our gadgets on
>> a
>> >> page using an ASP.NET wrapper.   When comparing how our gadgets render
>> in
>> >> comparison with the same gadgets on iGoogle, we tend to get content
>> >> shifting and the introduction of vertical/horizontal scrolls bars.
>> iGoogle
>> >> avoids these issues somehow.   A sample screenshot can be seen here
>> >> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know
>> of
>> >> a
>> >> workaround?    Many thanks.   Darren
>> >>
>> >
>> >
>>
>>
>>

Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Ryan Baxter <rb...@gmail.com>.
Dan knows best, he made that change ;)

If you want to change this behavior should be able to inject a
GadgetRewriter similar to the GadgetRenderingRewriter that is adding
the styles today.

On Tue, Oct 8, 2013 at 4:49 PM, Dan Dumont <dd...@apache.org> wrote:
> Again, this is there so that gadgets take ownership of the dom size they
> are given to render in.
>
> You likely have a margin/padding that is unintentionally pushing the
> content of the html/body outside of the bounds of what is available for
> your gadget, otherwise the html/body inside the iframe would not be
> scrolling.
>
>
> On Tue, Oct 8, 2013 at 4:39 PM, Darren Bond <db...@globalcad.com> wrote:
>
>> Hi Ryan,
>>
>> Relating to the unwanted scrollbars, our developer has come up with the
>> following findings:-
>>
>> In the beginning of each gadget Shindig library puts some small bit of CSS
>> code. It looks like this:
>>
>> html, body {
>> height: 100%;
>> overflow: auto;
>> width: 100%;
>> }
>>
>> It's hard to say why this gets injected. For me it looks unnecessary to
>> have
>> such properties for each gadget by default. iGoogle doesn't inject anything
>> similar and when I tried to put this piece of code on iGoogle (in Firebug)
>> same scrollbars appeared there. The problem can be easily solved by
>> resetting these properties back to default in the gadget's body. Of course
>> it is valid only for those gadgets whose code can be controlled by us.
>> Third-party gadgets which happened to have those scrollbars will keep them.
>>
>> Ryan are you able to shed some light on this injection of css code and
>> whether it can be removed?
>>
>> Kind regards,
>>
>> Darren
>>
>>
>> -----Original Message-----
>> From: Ryan Baxter [mailto:rbaxter85@gmail.com]
>> Sent: 24 September 2013 18:34
>> To: users@shindig.apache.org
>> Cc: dev@shindig.apache.org
>> Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>>
>> Can you reproduce the issues the sample common container in Shindig?
>> Or better yet build us a simple container that can reproduce the
>> issue?
>>
>> On Sun, Sep 22, 2013 at 3:12 PM, Darren Bond <db...@globalcad.com> wrote:
>> > Hi All,
>> >
>> > Unfortunately we're still struggling with this issue.
>> >
>> > Can anyone give us some helpful pointers where we might be going wrong
>> with
>> > the code below?
>> >
>> > Thanks.
>> >
>> > Darren
>> >
>> >
>> > -----Original Message-----
>> > From: Darren Bond [mailto:dbond@globalcad.com]
>> > Sent: 19 September 2013 09:24
>> > To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
>> > Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle
>> >
>> > Hi Stanton/Dan,
>> >
>> > Thank you for your helpful replies. I've received the following feedback
>> > from our developer:-
>> >
>> > Some gadgets get rendered correctly such as the TODO list gadget
>> > (http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.
>> >
>> > For example, we have problems with the Dictionary gadget
>> > (http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
>> > The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
>> > appears fickle in that sometimes vert/horiz scroll bars appear under home
>> > view and at other times not.
>> >
>> > All of them have <Require feature="dynamic-height"/> in their
>> specification.
>> > We use CSS padding for the html div tag that holds iframe coming from
>> > Shindig. Looking at the JavaScript source code used to render the
>> gadget:-
>> >
>> > CommonContainer.renderGadget = function (gadget, contentHolder,
>> > userPreference) {
>> >     var gadgetURL = gadget.Url;
>> >     var el = $(contentHolder).get(0);
>> >     var params;
>> >     if (userPreference == null) {
>> >         params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
>> >     } else {
>> >         params = { userPrefs: userPreference };
>> >     }
>> >     params["view"] = "home";
>> >     if (gadget.viewType == GadgetViewTypes.Canvas) {
>> >         params["view"] = "canvas";
>> >     }
>> >     params[osapi.container.RenderParam.WIDTH] = '100%';
>> >     var gadgetSite = CommonContainer.newGadgetSite(el);
>> >     CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
>> >     defaultUserPreference = {};
>> >     return gadgetSite;
>> > };
>> >
>> > Any thoughts as to how we can improve things?
>> >
>> > Kind regards,
>> >
>> > Darren
>> >
>> >
>> > -----Original Message-----
>> > From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of
>> Stanton
>> > Sievers
>> > Sent: 18 September 2013 16:34
>> > To: users@shindig.apache.org; dev@shindig.apache.org
>> > Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>> >
>> > + dev list
>> >
>> > Are you using dynamic height or width features in your gadget?
>> >
>> > Are the height and width properties set in your ModulePrefs? If so, what
>> > are they set to and are both containers honoring those values when
>> > rendering?
>> >
>> > Thanks,
>> > -Stanton
>> > On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
>> >
>> >>  Dear All,   We have a Shindig implementation and render our gadgets on
>> a
>> >> page using an ASP.NET wrapper.   When comparing how our gadgets render
>> in
>> >> comparison with the same gadgets on iGoogle, we tend to get content
>> >> shifting and the introduction of vertical/horizontal scrolls bars.
>> iGoogle
>> >> avoids these issues somehow.   A sample screenshot can be seen here
>> >> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know
>> of
>> >> a
>> >> workaround?    Many thanks.   Darren
>> >>
>> >
>> >
>>
>>
>>

Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Dan Dumont <dd...@apache.org>.
Again, this is there so that gadgets take ownership of the dom size they
are given to render in.

You likely have a margin/padding that is unintentionally pushing the
content of the html/body outside of the bounds of what is available for
your gadget, otherwise the html/body inside the iframe would not be
scrolling.


On Tue, Oct 8, 2013 at 4:39 PM, Darren Bond <db...@globalcad.com> wrote:

> Hi Ryan,
>
> Relating to the unwanted scrollbars, our developer has come up with the
> following findings:-
>
> In the beginning of each gadget Shindig library puts some small bit of CSS
> code. It looks like this:
>
> html, body {
> height: 100%;
> overflow: auto;
> width: 100%;
> }
>
> It's hard to say why this gets injected. For me it looks unnecessary to
> have
> such properties for each gadget by default. iGoogle doesn't inject anything
> similar and when I tried to put this piece of code on iGoogle (in Firebug)
> same scrollbars appeared there. The problem can be easily solved by
> resetting these properties back to default in the gadget's body. Of course
> it is valid only for those gadgets whose code can be controlled by us.
> Third-party gadgets which happened to have those scrollbars will keep them.
>
> Ryan are you able to shed some light on this injection of css code and
> whether it can be removed?
>
> Kind regards,
>
> Darren
>
>
> -----Original Message-----
> From: Ryan Baxter [mailto:rbaxter85@gmail.com]
> Sent: 24 September 2013 18:34
> To: users@shindig.apache.org
> Cc: dev@shindig.apache.org
> Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>
> Can you reproduce the issues the sample common container in Shindig?
> Or better yet build us a simple container that can reproduce the
> issue?
>
> On Sun, Sep 22, 2013 at 3:12 PM, Darren Bond <db...@globalcad.com> wrote:
> > Hi All,
> >
> > Unfortunately we're still struggling with this issue.
> >
> > Can anyone give us some helpful pointers where we might be going wrong
> with
> > the code below?
> >
> > Thanks.
> >
> > Darren
> >
> >
> > -----Original Message-----
> > From: Darren Bond [mailto:dbond@globalcad.com]
> > Sent: 19 September 2013 09:24
> > To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
> > Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle
> >
> > Hi Stanton/Dan,
> >
> > Thank you for your helpful replies. I've received the following feedback
> > from our developer:-
> >
> > Some gadgets get rendered correctly such as the TODO list gadget
> > (http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.
> >
> > For example, we have problems with the Dictionary gadget
> > (http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
> > The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
> > appears fickle in that sometimes vert/horiz scroll bars appear under home
> > view and at other times not.
> >
> > All of them have <Require feature="dynamic-height"/> in their
> specification.
> > We use CSS padding for the html div tag that holds iframe coming from
> > Shindig. Looking at the JavaScript source code used to render the
> gadget:-
> >
> > CommonContainer.renderGadget = function (gadget, contentHolder,
> > userPreference) {
> >     var gadgetURL = gadget.Url;
> >     var el = $(contentHolder).get(0);
> >     var params;
> >     if (userPreference == null) {
> >         params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
> >     } else {
> >         params = { userPrefs: userPreference };
> >     }
> >     params["view"] = "home";
> >     if (gadget.viewType == GadgetViewTypes.Canvas) {
> >         params["view"] = "canvas";
> >     }
> >     params[osapi.container.RenderParam.WIDTH] = '100%';
> >     var gadgetSite = CommonContainer.newGadgetSite(el);
> >     CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
> >     defaultUserPreference = {};
> >     return gadgetSite;
> > };
> >
> > Any thoughts as to how we can improve things?
> >
> > Kind regards,
> >
> > Darren
> >
> >
> > -----Original Message-----
> > From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of
> Stanton
> > Sievers
> > Sent: 18 September 2013 16:34
> > To: users@shindig.apache.org; dev@shindig.apache.org
> > Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
> >
> > + dev list
> >
> > Are you using dynamic height or width features in your gadget?
> >
> > Are the height and width properties set in your ModulePrefs? If so, what
> > are they set to and are both containers honoring those values when
> > rendering?
> >
> > Thanks,
> > -Stanton
> > On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
> >
> >>  Dear All,   We have a Shindig implementation and render our gadgets on
> a
> >> page using an ASP.NET wrapper.   When comparing how our gadgets render
> in
> >> comparison with the same gadgets on iGoogle, we tend to get content
> >> shifting and the introduction of vertical/horizontal scrolls bars.
> iGoogle
> >> avoids these issues somehow.   A sample screenshot can be seen here
> >> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know
> of
> >> a
> >> workaround?    Many thanks.   Darren
> >>
> >
> >
>
>
>

Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Dan Dumont <dd...@apache.org>.
Again, this is there so that gadgets take ownership of the dom size they
are given to render in.

You likely have a margin/padding that is unintentionally pushing the
content of the html/body outside of the bounds of what is available for
your gadget, otherwise the html/body inside the iframe would not be
scrolling.


On Tue, Oct 8, 2013 at 4:39 PM, Darren Bond <db...@globalcad.com> wrote:

> Hi Ryan,
>
> Relating to the unwanted scrollbars, our developer has come up with the
> following findings:-
>
> In the beginning of each gadget Shindig library puts some small bit of CSS
> code. It looks like this:
>
> html, body {
> height: 100%;
> overflow: auto;
> width: 100%;
> }
>
> It's hard to say why this gets injected. For me it looks unnecessary to
> have
> such properties for each gadget by default. iGoogle doesn't inject anything
> similar and when I tried to put this piece of code on iGoogle (in Firebug)
> same scrollbars appeared there. The problem can be easily solved by
> resetting these properties back to default in the gadget's body. Of course
> it is valid only for those gadgets whose code can be controlled by us.
> Third-party gadgets which happened to have those scrollbars will keep them.
>
> Ryan are you able to shed some light on this injection of css code and
> whether it can be removed?
>
> Kind regards,
>
> Darren
>
>
> -----Original Message-----
> From: Ryan Baxter [mailto:rbaxter85@gmail.com]
> Sent: 24 September 2013 18:34
> To: users@shindig.apache.org
> Cc: dev@shindig.apache.org
> Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>
> Can you reproduce the issues the sample common container in Shindig?
> Or better yet build us a simple container that can reproduce the
> issue?
>
> On Sun, Sep 22, 2013 at 3:12 PM, Darren Bond <db...@globalcad.com> wrote:
> > Hi All,
> >
> > Unfortunately we're still struggling with this issue.
> >
> > Can anyone give us some helpful pointers where we might be going wrong
> with
> > the code below?
> >
> > Thanks.
> >
> > Darren
> >
> >
> > -----Original Message-----
> > From: Darren Bond [mailto:dbond@globalcad.com]
> > Sent: 19 September 2013 09:24
> > To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
> > Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle
> >
> > Hi Stanton/Dan,
> >
> > Thank you for your helpful replies. I've received the following feedback
> > from our developer:-
> >
> > Some gadgets get rendered correctly such as the TODO list gadget
> > (http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.
> >
> > For example, we have problems with the Dictionary gadget
> > (http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
> > The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
> > appears fickle in that sometimes vert/horiz scroll bars appear under home
> > view and at other times not.
> >
> > All of them have <Require feature="dynamic-height"/> in their
> specification.
> > We use CSS padding for the html div tag that holds iframe coming from
> > Shindig. Looking at the JavaScript source code used to render the
> gadget:-
> >
> > CommonContainer.renderGadget = function (gadget, contentHolder,
> > userPreference) {
> >     var gadgetURL = gadget.Url;
> >     var el = $(contentHolder).get(0);
> >     var params;
> >     if (userPreference == null) {
> >         params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
> >     } else {
> >         params = { userPrefs: userPreference };
> >     }
> >     params["view"] = "home";
> >     if (gadget.viewType == GadgetViewTypes.Canvas) {
> >         params["view"] = "canvas";
> >     }
> >     params[osapi.container.RenderParam.WIDTH] = '100%';
> >     var gadgetSite = CommonContainer.newGadgetSite(el);
> >     CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
> >     defaultUserPreference = {};
> >     return gadgetSite;
> > };
> >
> > Any thoughts as to how we can improve things?
> >
> > Kind regards,
> >
> > Darren
> >
> >
> > -----Original Message-----
> > From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of
> Stanton
> > Sievers
> > Sent: 18 September 2013 16:34
> > To: users@shindig.apache.org; dev@shindig.apache.org
> > Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
> >
> > + dev list
> >
> > Are you using dynamic height or width features in your gadget?
> >
> > Are the height and width properties set in your ModulePrefs? If so, what
> > are they set to and are both containers honoring those values when
> > rendering?
> >
> > Thanks,
> > -Stanton
> > On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
> >
> >>  Dear All,   We have a Shindig implementation and render our gadgets on
> a
> >> page using an ASP.NET wrapper.   When comparing how our gadgets render
> in
> >> comparison with the same gadgets on iGoogle, we tend to get content
> >> shifting and the introduction of vertical/horizontal scrolls bars.
> iGoogle
> >> avoids these issues somehow.   A sample screenshot can be seen here
> >> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know
> of
> >> a
> >> workaround?    Many thanks.   Darren
> >>
> >
> >
>
>
>

RE: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Darren Bond <db...@globalcad.com>.
Hi Ryan,

Relating to the unwanted scrollbars, our developer has come up with the
following findings:-

In the beginning of each gadget Shindig library puts some small bit of CSS
code. It looks like this:

html, body {
height: 100%;
overflow: auto;
width: 100%;
}

It's hard to say why this gets injected. For me it looks unnecessary to have
such properties for each gadget by default. iGoogle doesn't inject anything
similar and when I tried to put this piece of code on iGoogle (in Firebug)
same scrollbars appeared there. The problem can be easily solved by
resetting these properties back to default in the gadget's body. Of course
it is valid only for those gadgets whose code can be controlled by us.
Third-party gadgets which happened to have those scrollbars will keep them.

Ryan are you able to shed some light on this injection of css code and
whether it can be removed?

Kind regards,

Darren


-----Original Message-----
From: Ryan Baxter [mailto:rbaxter85@gmail.com] 
Sent: 24 September 2013 18:34
To: users@shindig.apache.org
Cc: dev@shindig.apache.org
Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle

Can you reproduce the issues the sample common container in Shindig?
Or better yet build us a simple container that can reproduce the
issue?

On Sun, Sep 22, 2013 at 3:12 PM, Darren Bond <db...@globalcad.com> wrote:
> Hi All,
>
> Unfortunately we're still struggling with this issue.
>
> Can anyone give us some helpful pointers where we might be going wrong
with
> the code below?
>
> Thanks.
>
> Darren
>
>
> -----Original Message-----
> From: Darren Bond [mailto:dbond@globalcad.com]
> Sent: 19 September 2013 09:24
> To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
> Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle
>
> Hi Stanton/Dan,
>
> Thank you for your helpful replies. I've received the following feedback
> from our developer:-
>
> Some gadgets get rendered correctly such as the TODO list gadget
> (http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.
>
> For example, we have problems with the Dictionary gadget
> (http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
> The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
> appears fickle in that sometimes vert/horiz scroll bars appear under home
> view and at other times not.
>
> All of them have <Require feature="dynamic-height"/> in their
specification.
> We use CSS padding for the html div tag that holds iframe coming from
> Shindig. Looking at the JavaScript source code used to render the gadget:-
>
> CommonContainer.renderGadget = function (gadget, contentHolder,
> userPreference) {
>     var gadgetURL = gadget.Url;
>     var el = $(contentHolder).get(0);
>     var params;
>     if (userPreference == null) {
>         params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
>     } else {
>         params = { userPrefs: userPreference };
>     }
>     params["view"] = "home";
>     if (gadget.viewType == GadgetViewTypes.Canvas) {
>         params["view"] = "canvas";
>     }
>     params[osapi.container.RenderParam.WIDTH] = '100%';
>     var gadgetSite = CommonContainer.newGadgetSite(el);
>     CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
>     defaultUserPreference = {};
>     return gadgetSite;
> };
>
> Any thoughts as to how we can improve things?
>
> Kind regards,
>
> Darren
>
>
> -----Original Message-----
> From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of
Stanton
> Sievers
> Sent: 18 September 2013 16:34
> To: users@shindig.apache.org; dev@shindig.apache.org
> Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>
> + dev list
>
> Are you using dynamic height or width features in your gadget?
>
> Are the height and width properties set in your ModulePrefs? If so, what
> are they set to and are both containers honoring those values when
> rendering?
>
> Thanks,
> -Stanton
> On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
>
>>  Dear All,   We have a Shindig implementation and render our gadgets on a
>> page using an ASP.NET wrapper.   When comparing how our gadgets render in
>> comparison with the same gadgets on iGoogle, we tend to get content
>> shifting and the introduction of vertical/horizontal scrolls bars.
iGoogle
>> avoids these issues somehow.   A sample screenshot can be seen here
>> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
>> a
>> workaround?    Many thanks.   Darren
>>
>
>



RE: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Darren Bond <db...@globalcad.com>.
Hi Ryan,

Relating to the unwanted scrollbars, our developer has come up with the
following findings:-

In the beginning of each gadget Shindig library puts some small bit of CSS
code. It looks like this:

html, body {
height: 100%;
overflow: auto;
width: 100%;
}

It's hard to say why this gets injected. For me it looks unnecessary to have
such properties for each gadget by default. iGoogle doesn't inject anything
similar and when I tried to put this piece of code on iGoogle (in Firebug)
same scrollbars appeared there. The problem can be easily solved by
resetting these properties back to default in the gadget's body. Of course
it is valid only for those gadgets whose code can be controlled by us.
Third-party gadgets which happened to have those scrollbars will keep them.

Ryan are you able to shed some light on this injection of css code and
whether it can be removed?

Kind regards,

Darren


-----Original Message-----
From: Ryan Baxter [mailto:rbaxter85@gmail.com] 
Sent: 24 September 2013 18:34
To: users@shindig.apache.org
Cc: dev@shindig.apache.org
Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle

Can you reproduce the issues the sample common container in Shindig?
Or better yet build us a simple container that can reproduce the
issue?

On Sun, Sep 22, 2013 at 3:12 PM, Darren Bond <db...@globalcad.com> wrote:
> Hi All,
>
> Unfortunately we're still struggling with this issue.
>
> Can anyone give us some helpful pointers where we might be going wrong
with
> the code below?
>
> Thanks.
>
> Darren
>
>
> -----Original Message-----
> From: Darren Bond [mailto:dbond@globalcad.com]
> Sent: 19 September 2013 09:24
> To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
> Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle
>
> Hi Stanton/Dan,
>
> Thank you for your helpful replies. I've received the following feedback
> from our developer:-
>
> Some gadgets get rendered correctly such as the TODO list gadget
> (http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.
>
> For example, we have problems with the Dictionary gadget
> (http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
> The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
> appears fickle in that sometimes vert/horiz scroll bars appear under home
> view and at other times not.
>
> All of them have <Require feature="dynamic-height"/> in their
specification.
> We use CSS padding for the html div tag that holds iframe coming from
> Shindig. Looking at the JavaScript source code used to render the gadget:-
>
> CommonContainer.renderGadget = function (gadget, contentHolder,
> userPreference) {
>     var gadgetURL = gadget.Url;
>     var el = $(contentHolder).get(0);
>     var params;
>     if (userPreference == null) {
>         params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
>     } else {
>         params = { userPrefs: userPreference };
>     }
>     params["view"] = "home";
>     if (gadget.viewType == GadgetViewTypes.Canvas) {
>         params["view"] = "canvas";
>     }
>     params[osapi.container.RenderParam.WIDTH] = '100%';
>     var gadgetSite = CommonContainer.newGadgetSite(el);
>     CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
>     defaultUserPreference = {};
>     return gadgetSite;
> };
>
> Any thoughts as to how we can improve things?
>
> Kind regards,
>
> Darren
>
>
> -----Original Message-----
> From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of
Stanton
> Sievers
> Sent: 18 September 2013 16:34
> To: users@shindig.apache.org; dev@shindig.apache.org
> Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>
> + dev list
>
> Are you using dynamic height or width features in your gadget?
>
> Are the height and width properties set in your ModulePrefs? If so, what
> are they set to and are both containers honoring those values when
> rendering?
>
> Thanks,
> -Stanton
> On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
>
>>  Dear All,   We have a Shindig implementation and render our gadgets on a
>> page using an ASP.NET wrapper.   When comparing how our gadgets render in
>> comparison with the same gadgets on iGoogle, we tend to get content
>> shifting and the introduction of vertical/horizontal scrolls bars.
iGoogle
>> avoids these issues somehow.   A sample screenshot can be seen here
>> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
>> a
>> workaround?    Many thanks.   Darren
>>
>
>



Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Ryan Baxter <rb...@gmail.com>.
Can you reproduce the issues the sample common container in Shindig?
Or better yet build us a simple container that can reproduce the
issue?

On Sun, Sep 22, 2013 at 3:12 PM, Darren Bond <db...@globalcad.com> wrote:
> Hi All,
>
> Unfortunately we're still struggling with this issue.
>
> Can anyone give us some helpful pointers where we might be going wrong with
> the code below?
>
> Thanks.
>
> Darren
>
>
> -----Original Message-----
> From: Darren Bond [mailto:dbond@globalcad.com]
> Sent: 19 September 2013 09:24
> To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
> Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle
>
> Hi Stanton/Dan,
>
> Thank you for your helpful replies. I've received the following feedback
> from our developer:-
>
> Some gadgets get rendered correctly such as the TODO list gadget
> (http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.
>
> For example, we have problems with the Dictionary gadget
> (http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
> The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
> appears fickle in that sometimes vert/horiz scroll bars appear under home
> view and at other times not.
>
> All of them have <Require feature="dynamic-height"/> in their specification.
> We use CSS padding for the html div tag that holds iframe coming from
> Shindig. Looking at the JavaScript source code used to render the gadget:-
>
> CommonContainer.renderGadget = function (gadget, contentHolder,
> userPreference) {
>     var gadgetURL = gadget.Url;
>     var el = $(contentHolder).get(0);
>     var params;
>     if (userPreference == null) {
>         params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
>     } else {
>         params = { userPrefs: userPreference };
>     }
>     params["view"] = "home";
>     if (gadget.viewType == GadgetViewTypes.Canvas) {
>         params["view"] = "canvas";
>     }
>     params[osapi.container.RenderParam.WIDTH] = '100%';
>     var gadgetSite = CommonContainer.newGadgetSite(el);
>     CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
>     defaultUserPreference = {};
>     return gadgetSite;
> };
>
> Any thoughts as to how we can improve things?
>
> Kind regards,
>
> Darren
>
>
> -----Original Message-----
> From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of Stanton
> Sievers
> Sent: 18 September 2013 16:34
> To: users@shindig.apache.org; dev@shindig.apache.org
> Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>
> + dev list
>
> Are you using dynamic height or width features in your gadget?
>
> Are the height and width properties set in your ModulePrefs? If so, what
> are they set to and are both containers honoring those values when
> rendering?
>
> Thanks,
> -Stanton
> On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
>
>>  Dear All,   We have a Shindig implementation and render our gadgets on a
>> page using an ASP.NET wrapper.   When comparing how our gadgets render in
>> comparison with the same gadgets on iGoogle, we tend to get content
>> shifting and the introduction of vertical/horizontal scrolls bars. iGoogle
>> avoids these issues somehow.   A sample screenshot can be seen here
>> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
>> a
>> workaround?    Many thanks.   Darren
>>
>
>

Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Ryan Baxter <rb...@gmail.com>.
Can you reproduce the issues the sample common container in Shindig?
Or better yet build us a simple container that can reproduce the
issue?

On Sun, Sep 22, 2013 at 3:12 PM, Darren Bond <db...@globalcad.com> wrote:
> Hi All,
>
> Unfortunately we're still struggling with this issue.
>
> Can anyone give us some helpful pointers where we might be going wrong with
> the code below?
>
> Thanks.
>
> Darren
>
>
> -----Original Message-----
> From: Darren Bond [mailto:dbond@globalcad.com]
> Sent: 19 September 2013 09:24
> To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
> Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle
>
> Hi Stanton/Dan,
>
> Thank you for your helpful replies. I've received the following feedback
> from our developer:-
>
> Some gadgets get rendered correctly such as the TODO list gadget
> (http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.
>
> For example, we have problems with the Dictionary gadget
> (http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
> The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
> appears fickle in that sometimes vert/horiz scroll bars appear under home
> view and at other times not.
>
> All of them have <Require feature="dynamic-height"/> in their specification.
> We use CSS padding for the html div tag that holds iframe coming from
> Shindig. Looking at the JavaScript source code used to render the gadget:-
>
> CommonContainer.renderGadget = function (gadget, contentHolder,
> userPreference) {
>     var gadgetURL = gadget.Url;
>     var el = $(contentHolder).get(0);
>     var params;
>     if (userPreference == null) {
>         params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
>     } else {
>         params = { userPrefs: userPreference };
>     }
>     params["view"] = "home";
>     if (gadget.viewType == GadgetViewTypes.Canvas) {
>         params["view"] = "canvas";
>     }
>     params[osapi.container.RenderParam.WIDTH] = '100%';
>     var gadgetSite = CommonContainer.newGadgetSite(el);
>     CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
>     defaultUserPreference = {};
>     return gadgetSite;
> };
>
> Any thoughts as to how we can improve things?
>
> Kind regards,
>
> Darren
>
>
> -----Original Message-----
> From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of Stanton
> Sievers
> Sent: 18 September 2013 16:34
> To: users@shindig.apache.org; dev@shindig.apache.org
> Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle
>
> + dev list
>
> Are you using dynamic height or width features in your gadget?
>
> Are the height and width properties set in your ModulePrefs? If so, what
> are they set to and are both containers honoring those values when
> rendering?
>
> Thanks,
> -Stanton
> On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
>
>>  Dear All,   We have a Shindig implementation and render our gadgets on a
>> page using an ASP.NET wrapper.   When comparing how our gadgets render in
>> comparison with the same gadgets on iGoogle, we tend to get content
>> shifting and the introduction of vertical/horizontal scrolls bars. iGoogle
>> avoids these issues somehow.   A sample screenshot can be seen here
>> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
>> a
>> workaround?    Many thanks.   Darren
>>
>
>

RE: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Darren Bond <db...@globalcad.com>.
Hi All,

Unfortunately we're still struggling with this issue.

Can anyone give us some helpful pointers where we might be going wrong with
the code below?

Thanks.

Darren


-----Original Message-----
From: Darren Bond [mailto:dbond@globalcad.com] 
Sent: 19 September 2013 09:24
To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle

Hi Stanton/Dan,

Thank you for your helpful replies. I've received the following feedback
from our developer:-

Some gadgets get rendered correctly such as the TODO list gadget
(http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.

For example, we have problems with the Dictionary gadget
(http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
appears fickle in that sometimes vert/horiz scroll bars appear under home
view and at other times not.

All of them have <Require feature="dynamic-height"/> in their specification.
We use CSS padding for the html div tag that holds iframe coming from
Shindig. Looking at the JavaScript source code used to render the gadget:-

CommonContainer.renderGadget = function (gadget, contentHolder,
userPreference) {
    var gadgetURL = gadget.Url;
    var el = $(contentHolder).get(0);
    var params;
    if (userPreference == null) {
        params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
    } else {
        params = { userPrefs: userPreference };
    }
    params["view"] = "home";
    if (gadget.viewType == GadgetViewTypes.Canvas) {
        params["view"] = "canvas";
    }
    params[osapi.container.RenderParam.WIDTH] = '100%';
    var gadgetSite = CommonContainer.newGadgetSite(el);
    CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
    defaultUserPreference = {};
    return gadgetSite;
}; 

Any thoughts as to how we can improve things?

Kind regards,

Darren


-----Original Message-----
From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of Stanton
Sievers
Sent: 18 September 2013 16:34
To: users@shindig.apache.org; dev@shindig.apache.org
Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle

+ dev list

Are you using dynamic height or width features in your gadget?

Are the height and width properties set in your ModulePrefs? If so, what
are they set to and are both containers honoring those values when
rendering?

Thanks,
-Stanton
On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:

>  Dear All,   We have a Shindig implementation and render our gadgets on a
> page using an ASP.NET wrapper.   When comparing how our gadgets render in
> comparison with the same gadgets on iGoogle, we tend to get content
> shifting and the introduction of vertical/horizontal scrolls bars. iGoogle
> avoids these issues somehow.   A sample screenshot can be seen here
> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
> a
> workaround?    Many thanks.   Darren
>



Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Dan Dumont <dd...@apache.org>.
Shindig takes the approach of shifting render space management of the
gadget contents to the gadget.  The container may or may not support
increasing or decreasing available gadget space through apis like
dynamic-height and dynamic-width.  It also may choose to ignore the amount
of space requested by the gadget's view in the view declaration.

In new versions of shindig (and particular for html5 type gadgets) css is
injected into the gadget that sets html and body tags to width:100%,
height:100% and scrolling:auto.

Not sure if any of this is really impacting your gadget though, since it
looks like you're probably styling your main content to use the full width
of the gadget.
It may be that your css is using margins (instead of padding), setting
width to 100%, and therefore pushing the elements beyond the available
space.

I'd recommend using padding (if you're not already), and
box-sizing:border-box; so that padding will not extend the actual element
width beyond the specified width (100%).

On Wed, Sep 18, 2013 at 11:33 AM, Stanton Sievers <ss...@apache.org>wrote:

> + dev list
>
> Are you using dynamic height or width features in your gadget?
>
> Are the height and width properties set in your ModulePrefs? If so, what
> are they set to and are both containers honoring those values when
> rendering?
>
> Thanks,
> -Stanton
> On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:
>
> >  Dear All,   We have a Shindig implementation and render our gadgets on a
> > page using an ASP.NET wrapper.   When comparing how our gadgets render
> in
> > comparison with the same gadgets on iGoogle, we tend to get content
> > shifting and the introduction of vertical/horizontal scrolls bars.
> iGoogle
> > avoids these issues somehow.   A sample screenshot can be seen here
> > http://download.globalcad.com/Gadget_Appearance.png   Does anyone know
> of
> > a
> > workaround?    Many thanks.   Darren
> >
>

RE: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Darren Bond <db...@globalcad.com>.
Hi Stanton/Dan,

Thank you for your helpful replies. I've received the following feedback
from our developer:-

Some gadgets get rendered correctly such as the TODO list gadget
(http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.

For example, we have problems with the Dictionary gadget
(http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
appears fickle in that sometimes vert/horiz scroll bars appear under home
view and at other times not.

All of them have <Require feature="dynamic-height"/> in their specification.
We use CSS padding for the html div tag that holds iframe coming from
Shindig. Looking at the JavaScript source code used to render the gadget:-

CommonContainer.renderGadget = function (gadget, contentHolder,
userPreference) {
    var gadgetURL = gadget.Url;
    var el = $(contentHolder).get(0);
    var params;
    if (userPreference == null) {
        params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
    } else {
        params = { userPrefs: userPreference };
    }
    params["view"] = "home";
    if (gadget.viewType == GadgetViewTypes.Canvas) {
        params["view"] = "canvas";
    }
    params[osapi.container.RenderParam.WIDTH] = '100%';
    var gadgetSite = CommonContainer.newGadgetSite(el);
    CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
    defaultUserPreference = {};
    return gadgetSite;
}; 

Any thoughts as to how we can improve things?

Kind regards,

Darren


-----Original Message-----
From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of Stanton
Sievers
Sent: 18 September 2013 16:34
To: users@shindig.apache.org; dev@shindig.apache.org
Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle

+ dev list

Are you using dynamic height or width features in your gadget?

Are the height and width properties set in your ModulePrefs? If so, what
are they set to and are both containers honoring those values when
rendering?

Thanks,
-Stanton
On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:

>  Dear All,   We have a Shindig implementation and render our gadgets on a
> page using an ASP.NET wrapper.   When comparing how our gadgets render in
> comparison with the same gadgets on iGoogle, we tend to get content
> shifting and the introduction of vertical/horizontal scrolls bars. iGoogle
> avoids these issues somehow.   A sample screenshot can be seen here
> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
> a
> workaround?    Many thanks.   Darren
>



RE: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Darren Bond <db...@globalcad.com>.
Hi All,

Unfortunately we're still struggling with this issue.

Can anyone give us some helpful pointers where we might be going wrong with
the code below?

Thanks.

Darren


-----Original Message-----
From: Darren Bond [mailto:dbond@globalcad.com] 
Sent: 19 September 2013 09:24
To: 'dev@shindig.apache.org'; 'users@shindig.apache.org'
Subject: RE: Rendered Gadget Display Scrollbars unlike iGoogle

Hi Stanton/Dan,

Thank you for your helpful replies. I've received the following feedback
from our developer:-

Some gadgets get rendered correctly such as the TODO list gadget
(http://www.labpixies.com/campaigns/todo/todo.xml) but others don't.

For example, we have problems with the Dictionary gadget
(http://www.gstatic.com/ig/modules/dictionary/dictionary_v2.xml)
The YouTube gadget (www.gstatic.com/ig/modules/youtube/v3/youtube.xml)
appears fickle in that sometimes vert/horiz scroll bars appear under home
view and at other times not.

All of them have <Require feature="dynamic-height"/> in their specification.
We use CSS padding for the html div tag that holds iframe coming from
Shindig. Looking at the JavaScript source code used to render the gadget:-

CommonContainer.renderGadget = function (gadget, contentHolder,
userPreference) {
    var gadgetURL = gadget.Url;
    var el = $(contentHolder).get(0);
    var params;
    if (userPreference == null) {
        params = { userPrefs: cacheDefaultUserPreference[gadgetURL] };
    } else {
        params = { userPrefs: userPreference };
    }
    params["view"] = "home";
    if (gadget.viewType == GadgetViewTypes.Canvas) {
        params["view"] = "canvas";
    }
    params[osapi.container.RenderParam.WIDTH] = '100%';
    var gadgetSite = CommonContainer.newGadgetSite(el);
    CommonContainer.navigateGadget(gadgetSite, gadgetURL, {}, params);
    defaultUserPreference = {};
    return gadgetSite;
}; 

Any thoughts as to how we can improve things?

Kind regards,

Darren


-----Original Message-----
From: sieverssj@gmail.com [mailto:sieverssj@gmail.com] On Behalf Of Stanton
Sievers
Sent: 18 September 2013 16:34
To: users@shindig.apache.org; dev@shindig.apache.org
Subject: Re: Rendered Gadget Display Scrollbars unlike iGoogle

+ dev list

Are you using dynamic height or width features in your gadget?

Are the height and width properties set in your ModulePrefs? If so, what
are they set to and are both containers honoring those values when
rendering?

Thanks,
-Stanton
On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:

>  Dear All,   We have a Shindig implementation and render our gadgets on a
> page using an ASP.NET wrapper.   When comparing how our gadgets render in
> comparison with the same gadgets on iGoogle, we tend to get content
> shifting and the introduction of vertical/horizontal scrolls bars. iGoogle
> avoids these issues somehow.   A sample screenshot can be seen here
> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
> a
> workaround?    Many thanks.   Darren
>



Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Stanton Sievers <ss...@apache.org>.
+ dev list

Are you using dynamic height or width features in your gadget?

Are the height and width properties set in your ModulePrefs? If so, what
are they set to and are both containers honoring those values when
rendering?

Thanks,
-Stanton
On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:

>  Dear All,   We have a Shindig implementation and render our gadgets on a
> page using an ASP.NET wrapper.   When comparing how our gadgets render in
> comparison with the same gadgets on iGoogle, we tend to get content
> shifting and the introduction of vertical/horizontal scrolls bars. iGoogle
> avoids these issues somehow.   A sample screenshot can be seen here
> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
> a
> workaround?    Many thanks.   Darren
>

Re: Rendered Gadget Display Scrollbars unlike iGoogle

Posted by Stanton Sievers <ss...@apache.org>.
+ dev list

Are you using dynamic height or width features in your gadget?

Are the height and width properties set in your ModulePrefs? If so, what
are they set to and are both containers honoring those values when
rendering?

Thanks,
-Stanton
On Sep 18, 2013 4:31 AM, "Darren Bond" <db...@globalcad.com> wrote:

>  Dear All,   We have a Shindig implementation and render our gadgets on a
> page using an ASP.NET wrapper.   When comparing how our gadgets render in
> comparison with the same gadgets on iGoogle, we tend to get content
> shifting and the introduction of vertical/horizontal scrolls bars. iGoogle
> avoids these issues somehow.   A sample screenshot can be seen here
> http://download.globalcad.com/Gadget_Appearance.png   Does anyone know of
> a
> workaround?    Many thanks.   Darren
>