Skip to content

Slice.name is empty even though the name was definitely set in Photoshop #111

@kapooostin

Description

@kapooostin

I'm trying to read the slices data from a PSD file created with Adobe Photoshop 2025. In Ps (and in UXP environment via JS and BatchPlay) I can successfully read the slices names. But slice.to_hash returns empty names for all the slices in my document:

{
  :id=>374,
  :group_id=>123,
  :origin=>{
    :type=>"ESliceOrigin",
    :value=>"userGenerated"
  },
  :associated_layer_id=>nil,
  :name=>"",
  :type=>{
    :type=>"ESliceType",
    :value=>"Img "
  },
  :bounds=>{
    :left=>0,
    :top=>0,
    :right=>1064,
    :bottom=>686
  },
  :url=>"",
  :target=>"",
  :message=>"",
  :alt=>"",
  :cell_text_is_html=>true,
  :cell_text=>"",
  :horizontal_alignment=>{
    :type=>"ESliceHorzAlign",
    :value=>"default"
  },
  :vertical_alignment=>{
    :type=>"ESliceVertAlign",
    :value=>"default"
  },
  :color=>nil,
  :outset=>{
    :top=>0,
    :left=>0,
    :bottom=>0,
    :right=>0
  }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions