dcsimg
A Flash Developer Resource Site

Results 1 to 16 of 16

Thread: borderless content pane?

  1. #1
    Junior Member
    Join Date
    Feb 2005
    Posts
    18

    borderless content pane?

    Happy New Year Everyone,

    Is there a way to turn off the border on the content pane? I love the content pane's look and ease of use, but I was hoping to leave it borderless for my situation. I don't really code.

    Thanks,

    Trent

  2. #2
    Senior Member
    Join Date
    Dec 2002
    Location
    Netherlands
    Posts
    1,632
    There's no option to turn the border off.

    I don't know exactly what you want. If I look at your website, you used text on top of an image. If that's what you want, you also need to make the background transparent. You can work around with some coding but I don't know if that's a problem for you. If it's not, attach the following code to the frame the contentpane appears in.
    Code:
    contentpane1.onTransit = function(){
     this.l0._alpha = 0;
     this.l1.h.t.background = false;
     this.l2._alpha = 0;
     this.filters = [];
    }
    If your contentpane is named differently you have to change of course contentpane1 into the name of your contentpane.

  3. #3
    Junior Member
    Join Date
    Feb 2005
    Posts
    18
    The initial issue that started me on wanting to switch all my Dynamic Text boxes to Content Panes was that the scroll bars in Dynamic Text were not obvious enough to people who visit our site.

    http://aliciaandtrent.ca

    If you look now, I've switched to a content pane on our "Testimonials" page. The border around the Content Pane interferes with the flowers underneath, which is why I want to get rid of it. So there's no way to take out the border at all? I noticed there's a greyed out menu choice for "Border Color" at the bottom of the Content Pane's Properties box. Does that mean it may be coming?

    (Coding is a problem for me. But I've already got the text on the image the way I want it. I set the background to white and sent the content pane to the back in the change depth sub-menu. It has the additional and neat effect of making the picture actually show up underneath the scroll bars, which I like.)

  4. #4
    Senior Member
    Join Date
    Dec 2002
    Location
    Netherlands
    Posts
    1,632
    Okay, now I understand the problem.

    It's not a real border but a little shade that's added to the component.
    At the moment there's no easy GUI solution to fix it. It requires one line of code contentpane1.filters = []; .

    If you don't want to code anything a solution would be to cover up that 'border' with four thin white rectangles that are on top of the contentpane but under the flower image.

  5. #5
    Junior Member
    Join Date
    Feb 2005
    Posts
    18
    Where do I go to add/edit this line of code from within Koolmoves?

    Trent

  6. #6
    up to my .as in code Chris_Seahorn's Avatar
    Join Date
    Dec 2004
    Posts
    4,389
    He told you.

    Place this line in the frame of your movie the contentpane first appears in:

    contentpane1.filters = [];


    "contentpane1" should be whatever yours is named.

  7. #7
    Degenerate and baise art thou. docree's Avatar
    Join Date
    Feb 2001
    Location
    USA
    Posts
    390
    Kool Moves menu / views / actions and sounds overview
    [+ button] / action script --- there

    [Right Click] / Edit Frame Ations/Sounds
    [+ button] / Action Script... --- there

  8. #8
    Junior Member
    Join Date
    Feb 2005
    Posts
    18
    Thanks docree, chris and w. brants. I got it working just how I want it now. I'm going to redo all my Dynamic Text boxes to Content Panes to take advantage of those sexy scroll bars.

    Is there also a way to see all the coding for the whole .fun file which Koolmoves normally makes me so blissfully ignorant of? Maybe I can learn a little coding after all...

    Trent

  9. #9
    Polak Maly ant_Z's Avatar
    Join Date
    Jul 2006
    Location
    Poland
    Posts
    440
    hi, i know its a very old topic but... anyway.
    placing
    Code:
     contentpane1.l0._alpha = 0;
     contentpane1.l1.h.t.background = false;
     contentpane1.l2._alpha = 0;
     contentpane1.filters = [];
    in frames AS makes contentpane transparent all the time.
    ive searched in APIs and i couldnt find a way to make scrollbar background transparent... is there a possibility?

  10. #10
    Senior Member
    Join Date
    Dec 2002
    Location
    Netherlands
    Posts
    1,632
    You want only the scrollbar background transparent ?

  11. #11
    Polak Maly ant_Z's Avatar
    Join Date
    Jul 2006
    Location
    Poland
    Posts
    440
    i want background and scrolltrack transparent, buttons are also welcome. or just a list of all elements so i could do it analogically to background...

  12. #12
    Senior Member
    Join Date
    Dec 2002
    Location
    Netherlands
    Posts
    1,632
    Background is already mentioned above.

    Does this help ?

    contentpane1.vs.m_t.removeMovieClip();
    contentpane1.vs.m_b.removeMovieClip();

  13. #13
    Polak Maly ant_Z's Avatar
    Join Date
    Jul 2006
    Location
    Poland
    Posts
    440
    huh... that removes the scrolltrack and scrollbar... in this case its not a problem, anyway ive changed that into:

    contentpane1.vs.m_t._alpha = 50;
    contentpane1.vs.m_b._alpha = 50;

    because it looks much cooler. maybe its obvious to you, but ive figured out that contentpane is a set of lot of MCs. so... could you send me a list of those MCs so i can stop asking those 'dumb' questions? ive did a google search (thats why it took so long) but i didnt find anything interesting. please...

  14. #14
    Senior Member
    Join Date
    Dec 2002
    Location
    Netherlands
    Posts
    1,632
    All components are based on movieclips. Both KM and Flash components.
    You can create your own list of them. Place a component on stage and a dynamic textfield for output of the list. Add the following code to the frame
    Code:
    component = contentpane1; // component to examine
    output = txt1; // textfield used for output
    
    output.text = '';
    output_children = function(o,n){
     var i;
     if (n == undefined) n = o._name;
     for (i in o){
      var c = o[i];
      if (typeof(c)=='movieclip' && c!= component){
       var cn = n + '.' + c._name;
       output.text +=  cn + '\n';
       output_children(c,cn);
      }
     }
    }
    output_children(component);
    It should produce a list of all movieclips used. Be aware that there's no guarantee they will be the same in future versions of KM. If I have to make changes to components I always try to make them backwards compatible for the documented API functions but I can't promise there will never be changes in the internal structure of a component.

  15. #15
    Polak Maly ant_Z's Avatar
    Join Date
    Jul 2006
    Location
    Poland
    Posts
    440
    ive found something similiar in google, thanx anyway.
    i wanted a list with explanation, but ill handle this. with using list of mcs ill figure out MCs functions. ill post main functions here. thank you very much.

  16. #16
    Polak Maly ant_Z's Avatar
    Join Date
    Jul 2006
    Location
    Poland
    Posts
    440
    allright. it didnt help a lot :|
    anyway, vs and hs are horizontal and vertical scrolls, nav is also obvious and l0, l1, l2 seems to be something like level1, level2... but anyway i change they apperance, i get a shadow and a border around textfield.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center