/*************************************************************************
*
* ADOBE CONFIDENTIAL
* ___________________
*
*  Copyright 2011 Adobe Systems Incorporated
*  All Rights Reserved.
*
* NOTICE:  All information contained herein is, and remains
* the property of Adobe Systems Incorporated and its suppliers,
* if any.  The intellectual and technical concepts contained
* herein are proprietary to Adobe Systems Incorporated and its
* suppliers and are protected by trade secret or copyright law.
* Dissemination of this information or reproduction of this material
* is strictly forbidden unless prior written permission is obtained
* from Adobe Systems Incorporated.
**************************************************************************/

layout PIViewTextCSS
{
    view subview(grow: false,
                 height: 50,
                 identifier: "IDD_PROP_INSPECT_TEXT_CSS",
                 margin: 2,
                 name: "PIViewTextCSS",
                 parent_container_id: "primary_inspector",
                 resizeChildren: false,
                 shouldConstrain: true,
                 spacing: 5,
                 width: 700)
    {
        row(indent: 20,
            spacing: 5)
        {
            column(child_horizontal: @align_fill,
                   horizontal: @align_fill,
                   spacing: 2)
            {
                row(guide_mask: [ @guide_label ],
                    horizontal: @align_right,
                    spacing: 5)
                {
                    static_text(identifier: "IDC_STATIC_TARGETED_RULE",
                                name: "$$$/PropInspectTextCss/Label/TargetedRule=Targeted Rule");

                    popup(identifier: "IDC_COMBO_TARGETED_RULE",
                          include_custom_item: false,
                          popup_minimum_width_chars: 8,
                          tab_next_node: "IDC_BUTTON_EDIT_RULE",
                          vertical_scroll: true);
                }

                row(horizontal: @align_right,
                    spacing: 5)
                {
                    ownerdrawn_button(height: 19,
                                      identifier: "IDC_BUTTON_EDIT_RULE",
                                      name: "$$$/PropInspectTextCss/Button/EditRule=Edit Rule",
                                      tab_next_node: "IDC_BUTTON_EDIT",
                                      width: 110);

                    ownerdrawn_button(height: 19,
                                      identifier: "IDC_BUTTON_EDIT",
                                      name: "$$$/PropInspectTextCss/Button/CssPanel=CSS &Designer",
                                      tab_next_node: "IDC_COMBO_FONTFACE",
                                      width: 110);
                }
            }

            separator(height: 2,
                      horizontal: @align_default,
                      identifier: "IDC_STATIC_LINE",
                      minLength: 0,
                      orientation: @vertical,
                      vertical: @align_default,
                      width: 2);

            column(horizontal: @align_fill,
                   spacing: 0)
            {
                row(horizontal: @align_fill,
                    indent: 20,
                    spacing: 5)
                {
                    column(indent: 2)
                    {
                        static_text(horizontal: @align_right,
                                    identifier: "IDC_STATIC_FONT",
                                    name: "$$$/PropInspectTextCss/Label/Font=F&ont");

                        static_text(horizontal: @align_right,
                                    identifier: "IDC_STATIC_SIZE",
                                    name: "$$$/PropInspectTextCss/Label/Size=&Size");
                    }

                    column(spacing: 2)
                    {
                        row(spacing: 5)
                        {
                            combobox(identifier: "IDC_COMBO_FONTFACE",
                                     popup_minimum_width_chars: 8,
                                     tab_next_node: "IDC_COMBO_FONTSTYLE",
                                     vertical_scroll: true);

                            combobox(identifier: "IDC_COMBO_FONTSTYLE",
                                     popup_minimum_width_chars: 2,
                                     tab_next_node: "IDC_COMBO_FONTWEIGHT",
                                     vertical_scroll: true);

                            combobox(identifier: "IDC_COMBO_FONTWEIGHT",
                                     popup_minimum_width_chars: 2,
                                     tab_next_node: "IDC_COMBO_FONTSIZE",
                                     vertical_scroll: true);

                            column(spacing: 0)
                            {
                                row(spacing: 1)
                                {
                                    ownerdrawn_button(height: 18,
                                                      identifier: "IDC_CHECK_ALIGN_LEFT",
                                                      name: "$$$/PropInspectTextCss/IconButton/AlignLeft=Align left",
                                                      tab_next_node: "IDC_CHECK_ALIGN_CENTER",
                                                      width: 21);

                                    ownerdrawn_button(height: 18,
                                                      identifier: "IDC_CHECK_ALIGN_CENTER",
                                                      name: "$$$/PropInspectTextCss/IconButton/AlignCenter=Align center",
                                                      tab_next_node: "IDC_CHECK_ALIGN_RIGHT",
                                                      width: 21);

                                    ownerdrawn_button(height: 18,
                                                      identifier: "IDC_CHECK_ALIGN_RIGHT",
                                                      name: "$$$/PropInspectTextCss/IconButton/AlignRight=Align right",
                                                      tab_next_node: "IDC_CHECK_JUSTIFY",
                                                      width: 21);

                                    ownerdrawn_button(height: 18,
                                                      identifier: "IDC_CHECK_JUSTIFY",
                                                      name: "$$$/PropInspectTextCss/IconButton/Justify=Justify",
                                                      width: 21);
                                }
                            }
                        }

                        row(horizontal: @align_fill)
                        {
                            column(spacing: 0)
                            {
                                row(spacing: 5)
                                {
                                    column(spacing: 0)
                                    {
                                        row(placement: @place_overlay,
                                            spacing: 0)
                                        {
                                            combobox(identifier: "IDC_COMBO_FONTSIZE",
                                                     popup_minimum_width_chars: 4,
                                                     tab_next_node: "IDC_STYLE_TYPE_SIZE_UNITS_COMBO",
                                                     vertical_scroll: true);

                                            combobox(identifier: "IDC_STYLE_TYPE_SIZE_COMBO",
                                                     popup_minimum_width_chars: 4,
                                                     vertical_scroll: true);
                                        }
                                    }

                                    column()
                                    {
                                        popup(identifier: "IDC_STYLE_TYPE_SIZE_UNITS_COMBO",
                                              include_custom_item: false,
                                              items: [ { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item1/Px",
                                                         value: " " },
                                                       { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item2/Pt",
                                                         value: " " },
                                                       { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item3/In",
                                                         value: " " },
                                                       { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item4/Cm",
                                                         value: " " },
                                                       { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item5/Mm",
                                                         value: " " },
                                                       { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item6/Pc",
                                                         value: " " },
                                                       { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item7/Em",
                                                         value: " " },
                                                       { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item8/Ex",
                                                         value: " " },
                                                       { name: "$$$/PropInspectTextCss/StyleTypeSizeUnits/item9/",
                                                         value: " " } ],
                                              tab_next_node: "IDC_BUTTON_TEXT_COLOR",
                                              vertical_scroll: true);
                                    }
                                }
                            }

                            column(horizontal: @align_fill)
                            {
                                row(spacing: 0)
                                {
                                    column(indent: 1)
                                    {
                                        ownerdrawn_button(height: 18,
                                                          identifier: "IDC_BUTTON_TEXT_COLOR",
                                                          name: "$$$/PropInspectTextCss/IconButton/TextColor=Text &color",
                                                          tab_next_node: "IDC_EDIT_HEXCOLOR",
                                                          width: 21);
                                    }

                                    edit_text(auto_hscroll: true,
                                              characters: 9,
                                              identifier: "IDC_EDIT_HEXCOLOR",
                                              tab_next_node: "IDC_CHECK_BOLD");
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
