TUIMessageCellLayout.h 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. // Created by Tencent on 2023/06/09.
  2. // Copyright © 2023 Tencent. All rights reserved.
  3. #import <Foundation/Foundation.h>
  4. @import UIKit;
  5. NS_ASSUME_NONNULL_BEGIN
  6. /**
  7. *【Module Name】TUIMessageCellLayout
  8. *【Function description】The layout of message unit
  9. * - UI layouts for implementing various message units (text, voice, video, images, emoticons, etc.).
  10. * - When you want to adjust the interface layout in TUIKit, you can modify the corresponding properties in this layout.
  11. */
  12. @interface TUIMessageCellLayout : NSObject
  13. /**
  14. * The insets of message
  15. */
  16. @property(nonatomic, assign) UIEdgeInsets messageInsets;
  17. /**
  18. * The insets of bubble content.
  19. */
  20. @property(nonatomic, assign) UIEdgeInsets bubbleInsets;
  21. /**
  22. * The insets of avatar
  23. */
  24. @property(nonatomic, assign) UIEdgeInsets avatarInsets;
  25. /**
  26. * The size of avatar
  27. */
  28. @property(nonatomic, assign) CGSize avatarSize;
  29. /////////////////////////////////////////////////////////////////////////////////
  30. // Text Message Layout
  31. /////////////////////////////////////////////////////////////////////////////////
  32. /**
  33. * Getting text message (receive) layout
  34. */
  35. + (TUIMessageCellLayout *)incommingTextMessageLayout;
  36. /**
  37. * Getting text message (send) layout
  38. */
  39. + (TUIMessageCellLayout *)outgoingTextMessageLayout;
  40. /////////////////////////////////////////////////////////////////////////////////
  41. // Voice Message Layout
  42. /////////////////////////////////////////////////////////////////////////////////
  43. /**
  44. * Getting voice message (receive) layout
  45. */
  46. + (TUIMessageCellLayout *)incommingVoiceMessageLayout;
  47. /**
  48. * Getting voice message (send) layout
  49. */
  50. + (TUIMessageCellLayout *)outgoingVoiceMessageLayout;
  51. /////////////////////////////////////////////////////////////////////////////////
  52. // System Message Layout
  53. /////////////////////////////////////////////////////////////////////////////////
  54. /**
  55. * Getting system message layout
  56. */
  57. + (TUIMessageCellLayout *)systemMessageLayout;
  58. /////////////////////////////////////////////////////////////////////////////////
  59. // Image Message Layout
  60. /////////////////////////////////////////////////////////////////////////////////
  61. /**
  62. * Getting Image message layout
  63. */
  64. + (TUIMessageCellLayout *)incommingImageMessageLayout;
  65. + (TUIMessageCellLayout *)outgoingImageMessageLayout;
  66. /////////////////////////////////////////////////////////////////////////////////
  67. // Video Message Layout
  68. /////////////////////////////////////////////////////////////////////////////////
  69. /**
  70. * Getting video message layout
  71. */
  72. + (TUIMessageCellLayout *)incommingVideoMessageLayout;
  73. + (TUIMessageCellLayout *)outgoingVideoMessageLayout;
  74. /////////////////////////////////////////////////////////////////////////////////
  75. // Other Message Layout
  76. /////////////////////////////////////////////////////////////////////////////////
  77. /**
  78. * Getting receive message layout
  79. */
  80. + (TUIMessageCellLayout *)incommingMessageLayout;
  81. /**
  82. * Getting send message layout
  83. */
  84. + (TUIMessageCellLayout *)outgoingMessageLayout;
  85. @end
  86. NS_ASSUME_NONNULL_END